------------------------------------------------------------------------------------------------------------------------
      name:  <unnamed>
       log:  /home/horom/WhyLeadersFightDyadicReplication.log
  log type:  text
 opened on:  25 Nov 2015, 11:35:47

. 
. */ Table 3.1 */
. */ Uses leader peace year splines, not country peace year splines, as per footnote 57 on page 120 */
. 
. logit cwinit milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicine 
> religion activist careerpolitician creative business aristocratlandowner police militarycareer scienceeng bluecollar g
> ender totalspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure10
> 00 leaderpeaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if random==1, robust cluster(leaderid)

Iteration 0:   log pseudolikelihood = -7739.4781  
Iteration 1:   log pseudolikelihood = -7669.8774  
Iteration 2:   log pseudolikelihood = -7468.3004  
Iteration 3:   log pseudolikelihood = -7461.5736  
Iteration 4:   log pseudolikelihood = -7460.6459  
Iteration 5:   log pseudolikelihood = -7460.5083  
Iteration 6:   log pseudolikelihood = -7460.5067  
Iteration 7:   log pseudolikelihood = -7460.5067  

Logistic regression                               Number of obs   =     565055
                                                  Wald chi2(37)   =     202.01
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -7460.5067                 Pseudo R2       =     0.0360

                                   (Std. Err. adjusted for 2135 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .6502707   .2802284     2.32   0.020     .1010332    1.199508
             combat |   .3426081   .2029515     1.69   0.091    -.0551695    .7403857
              rebel |  -.0297844    .224922    -0.13   0.895    -.4706233    .4110546
             warwin |   .8360017   .2164588     3.86   0.000     .4117501    1.260253
            warloss |   .1811973   .2424986     0.75   0.455    -.2940913    .6564858
           rebelwin |   .3515057   .2109091     1.67   0.096    -.0618686    .7648801
          rebelloss |   .7835671   .2981165     2.63   0.009     .1992694    1.367865
           leveledu |   -.050515   .0904065    -0.56   0.576    -.2277085    .1266786
                age |   .0118123   .0069965     1.69   0.091    -.0019005    .0255252
            teacher |   .2022113   .2073799     0.98   0.330    -.2042459    .6086685
         journalism |     .08908   .3261164     0.27   0.785    -.5500964    .7282564
                law |  -.0481338   .1947981    -0.25   0.805     -.429931    .3336635
           medicine |  -.4343996   .2634496    -1.65   0.099    -.9507514    .0819522
           religion |   .7018273   .7355391     0.95   0.340    -.7398029    2.143457
           activist |   .1980631    .172808     1.15   0.252    -.1406344    .5367607
   careerpolitician |  -.0522742   .1441715    -0.36   0.717    -.3348452    .2302967
           creative |   .0733286   .6797816     0.11   0.914    -1.259019    1.405676
           business |  -.1861324   .1689543    -1.10   0.271    -.5172767    .1450119
aristocratlandowner |  -.2077114   .4228523    -0.49   0.623    -1.036487    .6210639
             police |   .2146806   .4147976     0.52   0.605    -.5983078    1.027669
     militarycareer |  -.4507828   .2848687    -1.58   0.114    -1.009115    .1075496
         scienceeng |   .0532673   .2804562     0.19   0.849    -.4964167    .6029514
         bluecollar |  -.0881903   .2246291    -0.39   0.695    -.5284552    .3520746
             gender |   .4329459   .3825219     1.13   0.258    -.3167832    1.182675
       totalspouses |  -.0204213   .0289376    -0.71   0.480     -.077138    .0362953
            married |   .1185129   .5816295     0.20   0.839     -1.02146    1.258486
     marriedinpower |  -.5351315   .3725858    -1.44   0.151    -1.265386    .1951231
           divorced |  -.1742247   .1522145    -1.14   0.252    -.4725595    .1241102
         childtotal |  -.0039593   .0079158    -0.50   0.617     -.019474    .0115555
       parstability |   .4574933   .2130803     2.15   0.032     .0398636     .875123
            illegit |  -.3768926   .2818849    -1.34   0.181     -.929377    .1755917
            royalty |   .3512749   .3719184     0.94   0.345    -.3776718    1.080222
       orphanbinary |   .0301958   .2731964     0.11   0.912    -.5052592    .5656509
   officetenure1000 |   .0153566   .0129615     1.18   0.236    -.0100474    .0407606
    leaderpeaceyrs1 |   .0081654   .0014787     5.52   0.000     .0052671    .0110637
    leaderpeaceyrs2 |   -.013824   .0047244    -2.93   0.003    -.0230837   -.0045643
    leaderpeaceyrs3 |   .0155462    .007993     1.94   0.052    -.0001198    .0312121
              _cons |    -6.9498   .8429215    -8.24   0.000    -8.601895   -5.297704
-------------------------------------------------------------------------------------
Note: 1891 failures and 0 successes completely determined.

. estimates store m1

. 
. predict p
(option pr assumed; Pr(cwinit))
(148178 missing values generated)

. label var p "Predicted Leader Risk Score"

. 
. drop if random==1
(638994 observations deleted)

. 
. logit cwinit p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if ran
> dom==0, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -7184.6102  
Iteration 1:   log pseudolikelihood = -6464.8062  
Iteration 2:   log pseudolikelihood = -5617.8807  
Iteration 3:   log pseudolikelihood = -5599.6798  
Iteration 4:   log pseudolikelihood = -5599.4912  
Iteration 5:   log pseudolikelihood = -5599.4912  

Logistic regression                               Number of obs   =     494839
                                                  Wald chi2(13)   =    2554.81
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -5599.4912                 Pseudo R2       =     0.2206

                             (Std. Err. adjusted for 27399 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   156.6802   12.63053    12.40   0.000     131.9248    181.4356
        dem1 |   .4437385   .1243321     3.57   0.000     .2000521    .6874249
        dem2 |   .7243657   .1319639     5.49   0.000     .4657213    .9830102
    jointdem |  -1.231484   .2128207    -5.79   0.000    -1.648605   -.8143629
    sideabof |   .3939202   .1466711     2.69   0.007     .1064501    .6813904
     defpact |    1.29265   .3109557     4.16   0.000     .6831877    1.902112
    contigld |   3.250726   .1224712    26.54   0.000     3.010687    3.490766
      syscon |   2.311386   1.006247     2.30   0.022     .3391788    4.283593
     satisdy |  -2.056709   .5531837    -3.72   0.000     -3.14093   -.9724892
      numGPs |   .2087997   .0473664     4.41   0.000     .1159632    .3016362
   cwpceyrs1 |   .0025313   .0001935    13.08   0.000     .0021522    .0029105
   cwpceyrs2 |   -.001855   .0001526   -12.16   0.000     -.002154   -.0015559
   cwpceyrs3 |   .0004171    .000039    10.69   0.000     .0003407    .0004936
       _cons |  -7.624898   .5263906   -14.49   0.000    -8.656605   -6.593192
------------------------------------------------------------------------------

. estimates store m2

. 
. margins, atmeans vsquish

Adjusted predictions                              Number of obs   =     494839
Model VCE    : Robust

Expression   : Pr(cwinit), predict()
at           : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
       _cons |   .0006966   .0000462    15.08   0.000      .000606    .0007872
------------------------------------------------------------------------------

. margins, atmeans at((p10)syscon) at((p90) syscon) at(contigld=0) at(contigld=1) at(dem1=1 dem2=1 jointdem=1) at((p10)s
> atisdy) at((p90)satisdy) at((p10)numGPs) at((p90)numGPs) at(defpact=0) at(defpact=1) at((p10)sideabof) at((p90)sideabo
> f) at((p10)p) at((p90)p) vsquish

Adjusted predictions                              Number of obs   =     494839
Model VCE    : Robust

Expression   : Pr(cwinit), predict()
1._at        : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =      .22651 (p10)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
2._at        : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =     .326193 (p90)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
3._at        : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =           0
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
4._at        : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =           1
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
5._at        : p               =    .0019177 (mean)
               dem1            =           1
               dem2            =           1
               jointdem        =           1
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
6._at        : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =      .33902 (p10)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
7._at        : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =     .519467 (p90)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
8._at        : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =           5 (p10)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
9._at        : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =           7 (p90)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
10._at       : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =           0
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
11._at       : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =           1
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
12._at       : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .0357421 (p10)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
13._at       : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .9663709 (p90)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
14._at       : p               =    .0003143 (p10)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)
15._at       : p               =     .003617 (p90)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
         _at |
          1  |   .0006268   .0000475    13.20   0.000     .0005337    .0007199
          2  |   .0007891   .0000717    11.01   0.000     .0006486    .0009296
          3  |   .0006351   .0000433    14.67   0.000     .0005503      .00072
          4  |   .0161381   .0016314     9.89   0.000     .0129406    .0193356
          5  |   .0005179   .0000815     6.35   0.000     .0003582    .0006776
          6  |   .0009099   .0000803    11.33   0.000     .0007526    .0010673
          7  |    .000628   .0000481    13.06   0.000     .0005337    .0007223
          8  |   .0005973   .0000436    13.69   0.000     .0005117    .0006828
          9  |   .0009065   .0000833    10.88   0.000     .0007432    .0010698
         10  |   .0006499   .0000457    14.21   0.000     .0005603    .0007396
         11  |   .0023633    .000692     3.42   0.001      .001007    .0037197
         12  |   .0005794   .0000581     9.97   0.000     .0004655    .0006933
         13  |   .0008358    .000075    11.15   0.000     .0006888    .0009828
         14  |   .0005419   .0000376    14.42   0.000     .0004683    .0006156
         15  |   .0009089   .0000634    14.34   0.000     .0007847    .0010331
------------------------------------------------------------------------------

. 
. */ Use these to generate Table 3.1 */
. */ Note that these totals are *very* slighty off Table 3.1 due to a last minute coding update not reflected in the tab
> le in the book */
. 
. */ Figure 3.14 */
. 
. margins, atmeans at((min)p) at((p10)p) at((p20)p) at((p30)p) at((p40)p) at((p50)p) at((p60)p) at((p70)p) at((p80)p) at
> ((p90)p)

Adjusted predictions                              Number of obs   =     494839
Model VCE    : Robust

Expression   : Pr(cwinit), predict()

1._at        : p               =    2.39e-18 (min)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

2._at        : p               =    .0003143 (p10)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

3._at        : p               =    .0009915 (p20)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

4._at        : p               =    .0012748 (p30)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

5._at        : p               =    .0014567 (p40)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

6._at        : p               =    .0016259 (p50)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

7._at        : p               =    .0017995 (p60)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

8._at        : p               =    .0020444 (p70)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

9._at        : p               =    .0025232 (p80)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

10._at       : p               =     .003617 (p90)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
         _at |
          1  |   .0005159   .0000364    14.17   0.000     .0004445    .0005873
          2  |   .0005419   .0000376    14.42   0.000     .0004683    .0006156
          3  |   .0006026   .0000406    14.85   0.000      .000523    .0006821
          4  |   .0006299   .0000421    14.97   0.000     .0005474    .0007124
          5  |   .0006481   .0000431    15.02   0.000     .0005635    .0007327
          6  |   .0006655   .0000442    15.05   0.000     .0005789    .0007521
          7  |   .0006838   .0000454    15.07   0.000     .0005949    .0007727
          8  |   .0007106   .0000471    15.07   0.000     .0006182     .000803
          9  |   .0007659   .0000511    14.98   0.000     .0006656    .0008661
         10  |   .0009089   .0000634    14.34   0.000     .0007847    .0010331
------------------------------------------------------------------------------

. 
. */ Appendix */
. 
. */ Regression Table for Table 3.1 */
. 
. esttab m1 m2 using AppendixTableA_10.rtf, replace onecell se pr2 t(3) b(a3) scalars(ll) legend label collabels(none) va
> rlabels(_cons Constant) star(* 0.10 ** 0.05 *** 0.01) mtitles("Leader Risk Model On First Half Of Data" "Combined Mode
> l On Second Half Of Data")
(output written to AppendixTableA_10.rtf)

. 
. */ Appendix Table with A). Dem High/Dem Low and B). Polity interaction instead of Democracy Dummy */
. 
. logit cwinit p demhigh demlow sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if random=
> =0, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -7184.6102  
Iteration 1:   log pseudolikelihood = -6465.5272  
Iteration 2:   log pseudolikelihood = -5618.7136  
Iteration 3:   log pseudolikelihood = -5600.3378  
Iteration 4:   log pseudolikelihood = -5600.1434  
Iteration 5:   log pseudolikelihood = -5600.1434  

Logistic regression                               Number of obs   =     494839
                                                  Wald chi2(12)   =    2499.20
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -5600.1434                 Pseudo R2       =     0.2205

                             (Std. Err. adjusted for 27399 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   156.4023   12.53273    12.48   0.000     131.8386     180.966
     demhigh |   .0523174   .0084978     6.16   0.000      .035662    .0689727
      demlow |  -.0419451   .0076265    -5.50   0.000    -.0568928   -.0269974
    sideabof |   .3592521   .1480889     2.43   0.015     .0690031    .6495011
     defpact |   1.280007   .3053562     4.19   0.000     .6815202    1.878494
    contigld |   3.270991   .1209063    27.05   0.000     3.034019    3.507963
      syscon |   2.198622   1.006813     2.18   0.029     .2253043    4.171939
     satisdy |  -1.971354   .5399396    -3.65   0.000    -3.029616   -.9130917
      numGPs |   .2151911   .0477506     4.51   0.000     .1216017    .3087805
   cwpceyrs1 |   .0025469   .0001941    13.12   0.000     .0021664    .0029274
   cwpceyrs2 |  -.0018674   .0001532   -12.19   0.000    -.0021677   -.0015672
   cwpceyrs3 |   .0004203   .0000392    10.72   0.000     .0003435    .0004972
       _cons |  -7.786634    .523153   -14.88   0.000    -8.811995   -6.761273
------------------------------------------------------------------------------

. estimates store m3

. 
. esttab m3 using AppendixTableA_11.rtf, replace onecell se pr2 t(3) b(a3) scalars(ll) legend label collabels(none) varla
> bels(_cons Constant) star(* 0.10 ** 0.05 *** 0.01) mtitles("Alternative Regime Type Measure: Dem Low")
(output written to AppendixTableA_11.rtf)

. 
. estimates clear

. clear

. 
. */ Results described on pp. 121-122 in Why Leaders Fight concerning alternative DVs for Table 3.1 */
. 
. use WhyLeadersFightDyadicReplication.dta, clear

. 
. */ Re-estimate Table 3.1 w/ force DV */
. 
. logit force2dv milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicin
> e religion activist careerpolitician creative business aristocratlandowner police militarycareer scienceeng bluecollar
>  gender totalspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure
> 1000 leaderpeaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if random==1, robust cluster(leaderid)

note: creative != 0 predicts failure perfectly
      creative dropped and 810 obs not used

Iteration 0:   log pseudolikelihood = -2666.9818  
Iteration 1:   log pseudolikelihood = -2585.8896  
Iteration 2:   log pseudolikelihood =  -2554.695  
Iteration 3:   log pseudolikelihood = -2550.6001  
Iteration 4:   log pseudolikelihood = -2549.9612  
Iteration 5:   log pseudolikelihood = -2549.3764  
Iteration 6:   log pseudolikelihood = -2548.7548  
Iteration 7:   log pseudolikelihood = -2548.3675  
Iteration 8:   log pseudolikelihood = -2548.2801  
Iteration 9:   log pseudolikelihood = -2548.2758  
Iteration 10:  log pseudolikelihood = -2548.2758  

Logistic regression                               Number of obs   =     564245
                                                  Wald chi2(36)   =     189.28
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -2548.2758                 Pseudo R2       =     0.0445

                                   (Std. Err. adjusted for 2132 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
           force2dv |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .4981857   .2370661     2.10   0.036     .0335447    .9628267
             combat |   .4487527    .257927     1.74   0.082    -.0567749    .9542803
              rebel |   .1803545   .2346569     0.77   0.442    -.2795646    .6402735
             warwin |   .6904184   .2706792     2.55   0.011     .1598969     1.22094
            warloss |  -.0993301   .3589438    -0.28   0.782     -.802847    .6041869
           rebelwin |   .5982298   .2199374     2.72   0.007     .1671604    1.029299
          rebelloss |    .819742   .2551365     3.21   0.001     .3196836      1.3198
           leveledu |  -.0358768   .1070647    -0.34   0.738    -.2457198    .1739661
                age |   .0007932   .0054044     0.15   0.883    -.0097992    .0113857
            teacher |   .1657784   .1808625     0.92   0.359    -.1887056    .5202624
         journalism |   .0888236   .3481477     0.26   0.799    -.5935334    .7711806
                law |   -.218758    .218394    -1.00   0.317    -.6468025    .2092864
           medicine |   .1472936   .3450547     0.43   0.669    -.5290012    .8235884
           religion |   .2000397   .4756257     0.42   0.674    -.7321695    1.132249
           activist |     .38492   .1805053     2.13   0.033     .0311361    .7387039
   careerpolitician |   .0122212   .1566183     0.08   0.938    -.2947451    .3191875
           creative |          0  (omitted)
           business |  -.2608094   .2531481    -1.03   0.303    -.7569705    .2353517
aristocratlandowner |  -.1193728    .469332    -0.25   0.799    -1.039247     .800501
             police |   .4418283   .5215112     0.85   0.397    -.5803148    1.463971
     militarycareer |  -.1666829    .246584    -0.68   0.499    -.6499788    .3166129
         scienceeng |  -.4566427   .4474357    -1.02   0.307    -1.333601    .4203151
         bluecollar |  -.2152006   .2428696    -0.89   0.376    -.6912164    .2608151
             gender |   .2417107   .5999909     0.40   0.687    -.9342498    1.417671
       totalspouses |   -.020335   .0307591    -0.66   0.509    -.0806217    .0399517
            married |  -1.180818   .5955512    -1.98   0.047    -2.348076   -.0135588
     marriedinpower |   .2671757   .4035028     0.66   0.508    -.5236752    1.058027
           divorced |   .0507825   .1808575     0.28   0.779    -.3036917    .4052566
         childtotal |   -.007972   .0175066    -0.46   0.649    -.0422842    .0263403
       parstability |   .5404876   .2384651     2.27   0.023     .0731046    1.007871
            illegit |    -.69871   .3454356    -2.02   0.043    -1.375751   -.0216686
            royalty |   .5834744   .4523975     1.29   0.197    -.3032085    1.470157
       orphanbinary |   .5506302   .2930165     1.88   0.060    -.0236716    1.124932
   officetenure1000 |  -.0072384   .0234479    -0.31   0.758    -.0531955    .0387187
    leaderpeaceyrs1 |   .0131719   .0039219     3.36   0.001     .0054852    .0208587
    leaderpeaceyrs2 |  -.0735595    .024156    -3.05   0.002    -.1209044   -.0262147
    leaderpeaceyrs3 |   .1350942   .0449805     3.00   0.003     .0469341    .2232543
              _cons |  -7.057936   .9272638    -7.61   0.000     -8.87534   -5.240532
-------------------------------------------------------------------------------------
Note: 11434 failures and 0 successes completely determined.

. predict p
(option pr assumed; Pr(force2dv))
(149877 missing values generated)

. label var p "Predicted Leader Risk Score"

. order p random

. 
. drop if random==1
(638994 observations deleted)

. 
. logit force2dv p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if r
> andom==0, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -2320.6393  
Iteration 1:   log pseudolikelihood = -1790.6883  
Iteration 2:   log pseudolikelihood = -1615.2009  
Iteration 3:   log pseudolikelihood = -1566.9482  
Iteration 4:   log pseudolikelihood = -1565.1333  
Iteration 5:   log pseudolikelihood = -1565.1234  
Iteration 6:   log pseudolikelihood = -1565.1234  

Logistic regression                               Number of obs   =     493984
                                                  Wald chi2(13)   =    1335.05
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -1565.1234                 Pseudo R2       =     0.3256

                             (Std. Err. adjusted for 27399 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
    force2dv |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   294.5474   47.93373     6.14   0.000      200.599    388.4958
        dem1 |   .5766492   .2239565     2.57   0.010     .1377026    1.015596
        dem2 |   .5810484   .2406627     2.41   0.016     .1093582    1.052739
    jointdem |  -1.866183   .4874545    -3.83   0.000    -2.821576   -.9107896
    sideabof |   .0995604   .2421659     0.41   0.681    -.3750761    .5741969
     defpact |   .6945222   .4077338     1.70   0.088    -.1046214    1.493666
    contigld |   4.307918   .2258607    19.07   0.000     3.865239    4.750597
      syscon |   1.362235   1.878432     0.73   0.468    -2.319424    5.043894
     satisdy |  -1.605573   .7162334    -2.24   0.025    -3.009365   -.2017813
      numGPs |   .0075732   .0920934     0.08   0.934    -.1729266     .188073
   cwpceyrs1 |   .0039169   .0005381     7.28   0.000     .0028624    .0049715
   cwpceyrs2 |  -.0029238   .0004375    -6.68   0.000    -.0037813   -.0020663
   cwpceyrs3 |   .0006798   .0001187     5.73   0.000     .0004471    .0009126
       _cons |  -7.739309    .890226    -8.69   0.000     -9.48412   -5.994498
------------------------------------------------------------------------------

. estimates store m1

. 
. clear

. use WhyLeadersFightDyadicReplication.dta, clear

. 
. */ Switch here to peace years based on the Carter & Signorino method because the model does not converge otherwise */
. logit fatalmid milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicin
> e religion activist careerpolitician creative business aristocratlandowner police militarycareer scienceeng bluecollar
>  gender totalspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure
> 1000 leadernoinit leadernoinit2 leadernoinit3 if random==1, robust cluster(leaderid)

note: creative != 0 predicts failure perfectly
      creative dropped and 810 obs not used

Iteration 0:   log pseudolikelihood =  -1580.622  
Iteration 1:   log pseudolikelihood = -1555.6281  
Iteration 2:   log pseudolikelihood = -1516.4583  
Iteration 3:   log pseudolikelihood = -1513.6804  
Iteration 4:   log pseudolikelihood = -1513.4017  
Iteration 5:   log pseudolikelihood =  -1513.299  
Iteration 6:   log pseudolikelihood = -1513.0577  
Iteration 7:   log pseudolikelihood = -1513.0062  
Iteration 8:   log pseudolikelihood = -1513.0057  
Iteration 9:   log pseudolikelihood = -1513.0057  

Logistic regression                               Number of obs   =     564245
                                                  Wald chi2(36)   =     155.01
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -1513.0057                 Pseudo R2       =     0.0428

                                   (Std. Err. adjusted for 2132 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
           fatalmid |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .5899927   .2905308     2.03   0.042     .0205628    1.159423
             combat |   .3045074   .3079584     0.99   0.323      -.29908    .9080948
              rebel |   .2743131    .223154     1.23   0.219    -.1630606    .7116869
             warwin |   .9621963   .2938086     3.27   0.001     .3863419    1.538051
            warloss |  -.1506534   .3415581    -0.44   0.659     -.820095    .5187882
           rebelwin |   .4989659   .2741994     1.82   0.069    -.0384551    1.036387
          rebelloss |   .1818735   .3421674     0.53   0.595    -.4887622    .8525093
           leveledu |  -.0426856   .1145653    -0.37   0.709    -.2672295    .1818583
                age |   .0086187   .0076967     1.12   0.263    -.0064666     .023704
            teacher |   .1580366   .2400026     0.66   0.510    -.3123597     .628433
         journalism |  -.2832971   .3641628    -0.78   0.437     -.997043    .4304488
                law |  -.2122261   .2759935    -0.77   0.442    -.7531635    .3287113
           medicine |   .4551378   .3726517     1.22   0.222    -.2752461    1.185522
           religion |    .271983   .4844437     0.56   0.575    -.6775092    1.221475
           activist |   .3113511   .2207679     1.41   0.158     -.121346    .7440483
   careerpolitician |   .0998932   .1988952     0.50   0.615    -.2899343    .4897206
           creative |          0  (omitted)
           business |   .0656591   .3006424     0.22   0.827    -.5235891    .6549073
aristocratlandowner |   .6195367   .3651261     1.70   0.090    -.0960972    1.335171
             police |  -.3599934   1.083521    -0.33   0.740    -2.483656     1.76367
     militarycareer |  -.0111786   .2655329    -0.04   0.966    -.5316135    .5092564
         scienceeng |  -.1289415   .4950264    -0.26   0.794    -1.099175    .8412924
         bluecollar |  -.0837824   .3064473    -0.27   0.785    -.6844079    .5168432
             gender |  -.1579377   .6375625    -0.25   0.804    -1.407537    1.091662
       totalspouses |  -.0383569   .0367647    -1.04   0.297    -.1104144    .0337005
            married |  -.2797263   .5895285    -0.47   0.635    -1.435181    .8757284
     marriedinpower |  -.1396987   .4324015    -0.32   0.747      -.98719    .7077927
           divorced |    .036071   .2354117     0.15   0.878    -.4253275    .4974694
         childtotal |  -.0851001   .0340211    -2.50   0.012    -.1517803   -.0184199
       parstability |   .3885441   .3050502     1.27   0.203    -.2093432    .9864315
            illegit |  -.4494621   .4983358    -0.90   0.367    -1.426182    .5272581
            royalty |   .2209072   .3779326     0.58   0.559     -.519827    .9616415
       orphanbinary |   .4935061   .4228748     1.17   0.243    -.3353133    1.322325
   officetenure1000 |   .0005095    .033193     0.02   0.988    -.0645475    .0655666
       leadernoinit |  -.1777192    .148286    -1.20   0.231    -.4683545     .112916
      leadernoinit2 |   .0121034   .0399674     0.30   0.762    -.0662314    .0904381
      leadernoinit3 |  -.0018203   .0024727    -0.74   0.462    -.0066667    .0030261
              _cons |  -7.852981   .9196332    -8.54   0.000    -9.655429   -6.050533
-------------------------------------------------------------------------------------
Note: 15949 failures and 0 successes completely determined.

. predict p
(option pr assumed; Pr(fatalmid))
(149877 missing values generated)

. label var p "Predicted Leader Risk Score"

. order p random

. 
. drop if random==1
(638994 observations deleted)

. 
. logit fatalmid p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if r
> andom==0, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -1541.5654  
Iteration 1:   log pseudolikelihood = -1194.4531  
Iteration 2:   log pseudolikelihood = -1078.5817  
Iteration 3:   log pseudolikelihood = -1045.7936  
Iteration 4:   log pseudolikelihood = -1044.1218  
Iteration 5:   log pseudolikelihood = -1044.0226  
Iteration 6:   log pseudolikelihood = -1044.0212  
Iteration 7:   log pseudolikelihood = -1044.0212  

Logistic regression                               Number of obs   =     493984
                                                  Wald chi2(13)   =     942.82
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -1044.0212                 Pseudo R2       =     0.3228

                             (Std. Err. adjusted for 27399 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
    fatalmid |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   666.3275   160.8172     4.14   0.000     351.1316    981.5234
        dem1 |   .4462713   .2901328     1.54   0.124    -.1223785    1.014921
        dem2 |   .5906003    .301776     1.96   0.050    -.0008699     1.18207
    jointdem |  -1.940232   .7428263    -2.61   0.009    -3.396145   -.4843193
    sideabof |  -.2049069   .3015711    -0.68   0.497    -.7959755    .3861617
     defpact |   .2623415   .5186267     0.51   0.613    -.7541481    1.278831
    contigld |   4.487665   .2740649    16.37   0.000     3.950508    5.024822
      syscon |  -.3199723    2.31686    -0.14   0.890    -4.860934    4.220989
     satisdy |  -1.703708   .8786548    -1.94   0.053    -3.425839    .0184241
      numGPs |  -.1530479   .1136299    -1.35   0.178    -.3757584    .0696625
   cwpceyrs1 |   .0040536   .0007491     5.41   0.000     .0025855    .0055218
   cwpceyrs2 |  -.0030796   .0006314    -4.88   0.000    -.0043172   -.0018421
   cwpceyrs3 |   .0007398   .0001822     4.06   0.000     .0003828    .0010969
       _cons |  -6.705389   1.037225    -6.46   0.000    -8.738314   -4.672465
------------------------------------------------------------------------------
Note: 536 failures and 0 successes completely determined.

. estimates store m2

. 
. esttab m1 m2 using AppendixTableA_12.rtf, replace onecell se pr2 t(3) b(a3) scalars(ll) legend label collabels(none) va
> rlabels(_cons Constant) star(* 0.10 ** 0.05 *** 0.01) mtitles("Both Sides Use Force DV" "Fatal Dispute DV")
(output written to AppendixTableA_12.rtf)

. 
. estimates clear

. clear

. 
. */ Results described on pp. 122-123 in Why Leaders Fight */
. 
. use WhyLeadersFightDyadicReplication.dta, clear

. 
. */ Re-estimate Table 3.1 */
. 
. logit cwinit milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicine 
> religion activist careerpolitician creative business aristocratlandowner police militarycareer scienceeng bluecollar g
> ender totalspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure10
> 00 leaderpeaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if random==1, robust cluster(leaderid)

Iteration 0:   log pseudolikelihood = -7739.4781  
Iteration 1:   log pseudolikelihood = -7669.8774  
Iteration 2:   log pseudolikelihood = -7468.3004  
Iteration 3:   log pseudolikelihood = -7461.5736  
Iteration 4:   log pseudolikelihood = -7460.6459  
Iteration 5:   log pseudolikelihood = -7460.5083  
Iteration 6:   log pseudolikelihood = -7460.5067  
Iteration 7:   log pseudolikelihood = -7460.5067  

Logistic regression                               Number of obs   =     565055
                                                  Wald chi2(37)   =     202.01
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -7460.5067                 Pseudo R2       =     0.0360

                                   (Std. Err. adjusted for 2135 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .6502707   .2802284     2.32   0.020     .1010332    1.199508
             combat |   .3426081   .2029515     1.69   0.091    -.0551695    .7403857
              rebel |  -.0297844    .224922    -0.13   0.895    -.4706233    .4110546
             warwin |   .8360017   .2164588     3.86   0.000     .4117501    1.260253
            warloss |   .1811973   .2424986     0.75   0.455    -.2940913    .6564858
           rebelwin |   .3515057   .2109091     1.67   0.096    -.0618686    .7648801
          rebelloss |   .7835671   .2981165     2.63   0.009     .1992694    1.367865
           leveledu |   -.050515   .0904065    -0.56   0.576    -.2277085    .1266786
                age |   .0118123   .0069965     1.69   0.091    -.0019005    .0255252
            teacher |   .2022113   .2073799     0.98   0.330    -.2042459    .6086685
         journalism |     .08908   .3261164     0.27   0.785    -.5500964    .7282564
                law |  -.0481338   .1947981    -0.25   0.805     -.429931    .3336635
           medicine |  -.4343996   .2634496    -1.65   0.099    -.9507514    .0819522
           religion |   .7018273   .7355391     0.95   0.340    -.7398029    2.143457
           activist |   .1980631    .172808     1.15   0.252    -.1406344    .5367607
   careerpolitician |  -.0522742   .1441715    -0.36   0.717    -.3348452    .2302967
           creative |   .0733286   .6797816     0.11   0.914    -1.259019    1.405676
           business |  -.1861324   .1689543    -1.10   0.271    -.5172767    .1450119
aristocratlandowner |  -.2077114   .4228523    -0.49   0.623    -1.036487    .6210639
             police |   .2146806   .4147976     0.52   0.605    -.5983078    1.027669
     militarycareer |  -.4507828   .2848687    -1.58   0.114    -1.009115    .1075496
         scienceeng |   .0532673   .2804562     0.19   0.849    -.4964167    .6029514
         bluecollar |  -.0881903   .2246291    -0.39   0.695    -.5284552    .3520746
             gender |   .4329459   .3825219     1.13   0.258    -.3167832    1.182675
       totalspouses |  -.0204213   .0289376    -0.71   0.480     -.077138    .0362953
            married |   .1185129   .5816295     0.20   0.839     -1.02146    1.258486
     marriedinpower |  -.5351315   .3725858    -1.44   0.151    -1.265386    .1951231
           divorced |  -.1742247   .1522145    -1.14   0.252    -.4725595    .1241102
         childtotal |  -.0039593   .0079158    -0.50   0.617     -.019474    .0115555
       parstability |   .4574933   .2130803     2.15   0.032     .0398636     .875123
            illegit |  -.3768926   .2818849    -1.34   0.181     -.929377    .1755917
            royalty |   .3512749   .3719184     0.94   0.345    -.3776718    1.080222
       orphanbinary |   .0301958   .2731964     0.11   0.912    -.5052592    .5656509
   officetenure1000 |   .0153566   .0129615     1.18   0.236    -.0100474    .0407606
    leaderpeaceyrs1 |   .0081654   .0014787     5.52   0.000     .0052671    .0110637
    leaderpeaceyrs2 |   -.013824   .0047244    -2.93   0.003    -.0230837   -.0045643
    leaderpeaceyrs3 |   .0155462    .007993     1.94   0.052    -.0001198    .0312121
              _cons |    -6.9498   .8429215    -8.24   0.000    -8.601895   -5.297704
-------------------------------------------------------------------------------------
Note: 1891 failures and 0 successes completely determined.

. predict p
(option pr assumed; Pr(cwinit))
(148178 missing values generated)

. label var p "Predicted Leader Risk Score"

. drop if random==1
(638994 observations deleted)

. logit cwinit p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if ran
> dom==0, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -7184.6102  
Iteration 1:   log pseudolikelihood = -6464.8062  
Iteration 2:   log pseudolikelihood = -5617.8807  
Iteration 3:   log pseudolikelihood = -5599.6798  
Iteration 4:   log pseudolikelihood = -5599.4912  
Iteration 5:   log pseudolikelihood = -5599.4912  

Logistic regression                               Number of obs   =     494839
                                                  Wald chi2(13)   =    2554.81
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -5599.4912                 Pseudo R2       =     0.2206

                             (Std. Err. adjusted for 27399 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   156.6802   12.63053    12.40   0.000     131.9248    181.4356
        dem1 |   .4437385   .1243321     3.57   0.000     .2000521    .6874249
        dem2 |   .7243657   .1319639     5.49   0.000     .4657213    .9830102
    jointdem |  -1.231484   .2128207    -5.79   0.000    -1.648605   -.8143629
    sideabof |   .3939202   .1466711     2.69   0.007     .1064501    .6813904
     defpact |    1.29265   .3109557     4.16   0.000     .6831877    1.902112
    contigld |   3.250726   .1224712    26.54   0.000     3.010687    3.490766
      syscon |   2.311386   1.006247     2.30   0.022     .3391788    4.283593
     satisdy |  -2.056709   .5531837    -3.72   0.000     -3.14093   -.9724892
      numGPs |   .2087997   .0473664     4.41   0.000     .1159632    .3016362
   cwpceyrs1 |   .0025313   .0001935    13.08   0.000     .0021522    .0029105
   cwpceyrs2 |   -.001855   .0001526   -12.16   0.000     -.002154   -.0015559
   cwpceyrs3 |   .0004171    .000039    10.69   0.000     .0003407    .0004936
       _cons |  -7.624898   .5263906   -14.49   0.000    -8.656605   -6.593192
------------------------------------------------------------------------------

. 
. */ pp. 122-123: generate predicted MID initiation scores for 99th percentile and 100th percentile of leader risk and c
> ompare to baseline */
. 
. margins, atmeans vsquish

Adjusted predictions                              Number of obs   =     494839
Model VCE    : Robust

Expression   : Pr(cwinit), predict()
at           : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
       _cons |   .0006966   .0000462    15.08   0.000      .000606    .0007872
------------------------------------------------------------------------------

. margins, atmeans at((p99)p) at((max)p)

Adjusted predictions                              Number of obs   =     494839
Model VCE    : Robust

Expression   : Pr(cwinit), predict()

1._at        : p               =    .0080252 (p99)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

2._at        : p               =    .0289596 (max)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               sideabof        =    .5035722 (mean)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
         _at |
          1  |   .0018117   .0001841     9.84   0.000     .0014508    .0021726
          2  |   .0460156   .0152772     3.01   0.003     .0160728    .0759583
------------------------------------------------------------------------------

. 
. */ pp. 122-123: generate leader risk score for when both side A and side B have significant material power and vary le
> ader risk */
. 
. logit cwinit p dem1 dem2 jointdem cap_1 cap_2 defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if 
> random==0, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -7184.6102  
Iteration 1:   log pseudolikelihood = -6380.8852  
Iteration 2:   log pseudolikelihood =  -5442.175  
Iteration 3:   log pseudolikelihood = -5414.8353  
Iteration 4:   log pseudolikelihood = -5414.3336  
Iteration 5:   log pseudolikelihood = -5414.3334  

Logistic regression                               Number of obs   =     494839
                                                  Wald chi2(14)   =    2075.65
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -5414.3334                 Pseudo R2       =     0.2464

                             (Std. Err. adjusted for 27399 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   98.85793   16.70543     5.92   0.000      66.1159       131.6
        dem1 |   .2784467   .1338876     2.08   0.038     .0160318    .5408617
        dem2 |   .5703462   .1428003     3.99   0.000     .2904627    .8502296
    jointdem |   -1.04541   .2249405    -4.65   0.000    -1.486285   -.6045346
       cap_1 |   9.918149   .9344457    10.61   0.000     8.086669    11.74963
       cap_2 |   7.830179   1.038989     7.54   0.000     5.793798    9.866559
     defpact |   .8323075   .2793486     2.98   0.003     .2847943    1.379821
    contigld |   3.082791    .131103    23.51   0.000     2.825834    3.339748
      syscon |  -1.476704   1.133723    -1.30   0.193     -3.69876    .7453519
     satisdy |  -1.374386   .5304755    -2.59   0.010    -2.414099   -.3346734
      numGPs |   .1388102    .047023     2.95   0.003     .0466468    .2309736
   cwpceyrs1 |   .0025559   .0001932    13.23   0.000     .0021772    .0029346
   cwpceyrs2 |  -.0018716   .0001522   -12.30   0.000    -.0021699   -.0015733
   cwpceyrs3 |   .0004204   .0000388    10.82   0.000     .0003442    .0004965
       _cons |   -6.30962   .5375253   -11.74   0.000     -7.36315   -5.256089
------------------------------------------------------------------------------

. margins, at((mean) _all (max) cap_1 (max) cap_2 (mean) p) at((mean) _all (max) cap_1 (max) cap_2 (p98) p) at((mean) _a
> ll (max) cap_1 (max) cap_2 (max) p)

Adjusted predictions                              Number of obs   =     494839
Model VCE    : Robust

Expression   : Pr(cwinit), predict()

1._at        : p               =    .0019177 (mean)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               cap_1           =     .383864 (max)
               cap_2           =     .383864 (max)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

2._at        : p               =    .0063363 (p98)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               cap_1           =     .383864 (max)
               cap_2           =     .383864 (max)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

3._at        : p               =    .0289596 (max)
               dem1            =    .3024034 (mean)
               dem2            =    .2965005 (mean)
               jointdem        =    .0939659 (mean)
               cap_1           =     .383864 (max)
               cap_2           =     .383864 (max)
               defpact         =      .05367 (mean)
               contigld        =    .0284335 (mean)
               syscon          =    .2722184 (mean)
               satisdy         =    .4690242 (mean)
               numGPs          =    5.737434 (mean)
               cwpceyrs1       =   -16435.61 (mean)
               cwpceyrs2       =   -31855.33 (mean)
               cwpceyrs3       =   -45278.14 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
         _at |
          1  |   .3336677   .1234538     2.70   0.007     .0917027    .5756328
          2  |   .4366352   .1349126     3.24   0.001     .1722113    .7010591
          3  |   .8788584   .0700643    12.54   0.000      .741535    1.016182
------------------------------------------------------------------------------

. 
. clear

. 
. */ Figure 3.15 */
. */ Load full dataset, generate variable to distinguish which side the balance of forces favors, and show how that vari
> es across monadic leader risk score */
. 
. use WhyLeadersFightDyadicReplication.dta, clear

. 
. sum sideabof

    Variable |       Obs        Mean    Std. Dev.       Min        Max
-------------+--------------------------------------------------------
    sideabof |   1278364    .5001306    .3680123          0          1

. gen test=.
(1278368 missing values generated)

. replace test=0 if sideabof<.5001306
(639504 real changes made)

. replace test=1 if sideabof>.5001306 & sideabof<1
(637915 real changes made)

. 
. twoway (scatter monadicleaderrisk sideabof if cwinit==1 & test==0, sort mcolor(gs10)) (scatter monadicleaderrisk sidea
> bof if cwinit==1 & test==1, sort mcolor(black)), ytitle(Leader Risk Score (0 = Low, 1 = High)) ytitle(, margin(medsmal
> l)) ylabel(, nogrid) xtitle(Balance of Forces (0 = 100% Side B, 1 = 100% Side A)) xtitle(, margin(medsmall)) legend(or
> der(1 "Balance of Forces = 100% Side B to Equal" 2 "Balance of Forces = Equal to 100% Side A") r(2) region(lcolor(whit
> e))) graphregion(fcolor(white) lcolor(white) ifcolor(white) ilcolor(white)) plotregion(fcolor(white) lcolor(white) ifc
> olor(white) ilcolor(white))

. 
. graph save Graph Figure3_15.gph, replace
(file Figure3_15.gph saved)

. 
. estimates clear

. clear

. 
. */ Figure 3.17 */
. */ Summarize p, substitute min and max, and generate predicted values */
. 
. use WhyLeadersFightDyadicReplication.dta, clear

. 
. logit cwinit milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicine 
> religion activist careerpolitician creative business aristocratlandowner police militarycareer scienceeng bluecollar g
> ender totalspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure10
> 00 leaderpeaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if random==1, robust cluster(leaderid)

Iteration 0:   log pseudolikelihood = -7739.4781  
Iteration 1:   log pseudolikelihood = -7669.8774  
Iteration 2:   log pseudolikelihood = -7468.3004  
Iteration 3:   log pseudolikelihood = -7461.5736  
Iteration 4:   log pseudolikelihood = -7460.6459  
Iteration 5:   log pseudolikelihood = -7460.5083  
Iteration 6:   log pseudolikelihood = -7460.5067  
Iteration 7:   log pseudolikelihood = -7460.5067  

Logistic regression                               Number of obs   =     565055
                                                  Wald chi2(37)   =     202.01
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -7460.5067                 Pseudo R2       =     0.0360

                                   (Std. Err. adjusted for 2135 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .6502707   .2802284     2.32   0.020     .1010332    1.199508
             combat |   .3426081   .2029515     1.69   0.091    -.0551695    .7403857
              rebel |  -.0297844    .224922    -0.13   0.895    -.4706233    .4110546
             warwin |   .8360017   .2164588     3.86   0.000     .4117501    1.260253
            warloss |   .1811973   .2424986     0.75   0.455    -.2940913    .6564858
           rebelwin |   .3515057   .2109091     1.67   0.096    -.0618686    .7648801
          rebelloss |   .7835671   .2981165     2.63   0.009     .1992694    1.367865
           leveledu |   -.050515   .0904065    -0.56   0.576    -.2277085    .1266786
                age |   .0118123   .0069965     1.69   0.091    -.0019005    .0255252
            teacher |   .2022113   .2073799     0.98   0.330    -.2042459    .6086685
         journalism |     .08908   .3261164     0.27   0.785    -.5500964    .7282564
                law |  -.0481338   .1947981    -0.25   0.805     -.429931    .3336635
           medicine |  -.4343996   .2634496    -1.65   0.099    -.9507514    .0819522
           religion |   .7018273   .7355391     0.95   0.340    -.7398029    2.143457
           activist |   .1980631    .172808     1.15   0.252    -.1406344    .5367607
   careerpolitician |  -.0522742   .1441715    -0.36   0.717    -.3348452    .2302967
           creative |   .0733286   .6797816     0.11   0.914    -1.259019    1.405676
           business |  -.1861324   .1689543    -1.10   0.271    -.5172767    .1450119
aristocratlandowner |  -.2077114   .4228523    -0.49   0.623    -1.036487    .6210639
             police |   .2146806   .4147976     0.52   0.605    -.5983078    1.027669
     militarycareer |  -.4507828   .2848687    -1.58   0.114    -1.009115    .1075496
         scienceeng |   .0532673   .2804562     0.19   0.849    -.4964167    .6029514
         bluecollar |  -.0881903   .2246291    -0.39   0.695    -.5284552    .3520746
             gender |   .4329459   .3825219     1.13   0.258    -.3167832    1.182675
       totalspouses |  -.0204213   .0289376    -0.71   0.480     -.077138    .0362953
            married |   .1185129   .5816295     0.20   0.839     -1.02146    1.258486
     marriedinpower |  -.5351315   .3725858    -1.44   0.151    -1.265386    .1951231
           divorced |  -.1742247   .1522145    -1.14   0.252    -.4725595    .1241102
         childtotal |  -.0039593   .0079158    -0.50   0.617     -.019474    .0115555
       parstability |   .4574933   .2130803     2.15   0.032     .0398636     .875123
            illegit |  -.3768926   .2818849    -1.34   0.181     -.929377    .1755917
            royalty |   .3512749   .3719184     0.94   0.345    -.3776718    1.080222
       orphanbinary |   .0301958   .2731964     0.11   0.912    -.5052592    .5656509
   officetenure1000 |   .0153566   .0129615     1.18   0.236    -.0100474    .0407606
    leaderpeaceyrs1 |   .0081654   .0014787     5.52   0.000     .0052671    .0110637
    leaderpeaceyrs2 |   -.013824   .0047244    -2.93   0.003    -.0230837   -.0045643
    leaderpeaceyrs3 |   .0155462    .007993     1.94   0.052    -.0001198    .0312121
              _cons |    -6.9498   .8429215    -8.24   0.000    -8.601895   -5.297704
-------------------------------------------------------------------------------------
Note: 1891 failures and 0 successes completely determined.

. 
. predict p
(option pr assumed; Pr(cwinit))
(148178 missing values generated)

. label var p "Predicted Leader Risk Score"

. 
. drop if random==1
(638994 observations deleted)

. 
. summarize p if random==0

    Variable |       Obs        Mean    Std. Dev.       Min        Max
-------------+--------------------------------------------------------
           p |    565135     .001886    .0015099   2.39e-18   .0289596

. 
. gen ppolity=p*polity21
(103333 missing values generated)

. label variable ppolity "Polity * Predicted Leader Risk Score"

. 
. estsimp logit cwinit p ppolity polity21 sideabof defpact contigld syscon cwpceyrs1 cwpceyrs2 cwpceyrs3 if random==0, r
> obust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -7558.7445
Iteration 1:   log pseudolikelihood = -6955.7453
Iteration 2:   log pseudolikelihood = -6174.8752
Iteration 3:   log pseudolikelihood = -6014.7921
Iteration 4:   log pseudolikelihood = -5998.7426
Iteration 5:   log pseudolikelihood = -5998.4522
Iteration 6:   log pseudolikelihood =  -5998.452

Logistic regression                               Number of obs   =     536041
                                                  Wald chi2(10)   =    2256.25
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood =  -5998.452                 Pseudo R2       =     0.2064

                             (Std. Err. adjusted for 29328 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   200.3371   25.91744     7.73   0.000     149.5398    251.1343
     ppolity |  -3.430952   1.535111    -2.23   0.025    -6.439715   -.4221889
    polity21 |   .0138028   .0071077     1.94   0.052     -.000128    .0277337
    sideabof |   .2473483   .1462619     1.69   0.091    -.0393198    .5340164
     defpact |   .1303856   .1324982     0.98   0.325     -.129306    .3900772
    contigld |   3.141709   .1169275    26.87   0.000     2.912535    3.370883
      syscon |   2.295909   .9071397     2.53   0.011     .5179475     4.07387
   cwpceyrs1 |   .0026492    .000188    14.09   0.000     .0022807    .0030176
   cwpceyrs2 |  -.0019588   .0001475   -13.28   0.000    -.0022478   -.0016698
   cwpceyrs3 |    .000447   .0000374    11.96   0.000     .0003737    .0005202
       _cons |  -7.144809    .295886   -24.15   0.000    -7.724734   -6.564883
------------------------------------------------------------------------------

Simulating main parameters.  Please wait....
% of simulations completed: 9% 18% 27% 36% 45% 54% 63% 72% 81% 90% 100% 

Number of simulations  : 1000
Names of new variables : b1 b2 b3 b4 b5 b6 b7 b8 b9 b10 b11

. 
. setx mean

. simqi, pr

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9992657     .0000489     .9991664    .9993572
              Pr(cwinit=1) |   .0007343     .0000489     .0006428    .0008335

. 
. setx p max polity21 1 ppolity 1*.0289596

. simqi, pr genpr(max1)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .8534813     .0866582     .6329814    .9626598
              Pr(cwinit=1) |   .1465187     .0866582     .0373402    .3670185

Simqi generated the following new variable(s): max1

. setx p max polity21 2 ppolity 2*.0289596

. simqi, pr genpr(max2)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .8651402     .0775246     .6681521    .9635052
              Pr(cwinit=1) |   .1348598     .0775246     .0364948     .331848

Simqi generated the following new variable(s): max2

. setx p max polity21 3 ppolity 3*.0289596

. simqi, pr genpr(max3)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |    .876058     .0689275     .7033539    .9646975
              Pr(cwinit=1) |    .123942     .0689275     .0353025    .2966461

Simqi generated the following new variable(s): max3

. setx p max polity21 4 ppolity 4*.0289596

. simqi, pr genpr(max4)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .8862345     .0609272     .7347258     .965612
              Pr(cwinit=1) |   .1137655     .0609272      .034388    .2652742

Simqi generated the following new variable(s): max4

. setx p max polity21 5 ppolity 5*.0289596

. simqi, pr genpr(max5)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .8956785     .0535703     .7645269    .9666425
              Pr(cwinit=1) |   .1043215     .0535703     .0333575    .2354731

Simqi generated the following new variable(s): max5

. setx p max polity21 6 ppolity 6*.0289596

. simqi, pr genpr(max6)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9044076     .0468875     .7902005    .9678228
              Pr(cwinit=1) |   .0955924     .0468875     .0321772    .2097995

Simqi generated the following new variable(s): max6

. setx p max polity21 7 ppolity 7*.0289596

. simqi, pr genpr(max7)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9124467     .0408915     .8127047    .9692547
              Pr(cwinit=1) |   .0875533     .0408915     .0307453    .1872953

Simqi generated the following new variable(s): max7

. setx p max polity21 8 ppolity 8*.0289596

. simqi, pr genpr(max8)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9198269     .0355779     .8338699    .9705739
              Pr(cwinit=1) |   .0801731     .0355779     .0294261    .1661301

Simqi generated the following new variable(s): max8

. setx p max polity21 9 ppolity 9*.0289596

. simqi, pr genpr(max9)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9265836     .0309277     .8508739    .9717364
              Pr(cwinit=1) |   .0734164     .0309277     .0282636     .149126

Simqi generated the following new variable(s): max9

. setx p max polity21 10 ppolity 10*.0289596

. simqi, pr genpr(max10)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9327556       .02691     .8664585    .9724292
              Pr(cwinit=1) |   .0672444       .02691     .0275708    .1335415

Simqi generated the following new variable(s): max10

. setx p max polity21 11 ppolity 11*.0289596

. simqi, pr genpr(max11)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |    .938383     .0234862     .8803874    .9730196
              Pr(cwinit=1) |    .061617     .0234862     .0269804    .1196126

Simqi generated the following new variable(s): max11

. setx p max polity21 12 ppolity 12*.0289596

. simqi, pr genpr(max12)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9435065     .0206121     .8946384     .974188
              Pr(cwinit=1) |   .0564935     .0206121      .025812    .1053616

Simqi generated the following new variable(s): max12

. setx p max polity21 13 ppolity 13*.0289596

. simqi, pr genpr(max13)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9481663     .0182407     .9056882    .9762014
              Pr(cwinit=1) |   .0518337     .0182407     .0237986    .0943118

Simqi generated the following new variable(s): max13

. setx p max polity21 14 ppolity 14*.0289596

. simqi, pr genpr(max14)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9524011     .0163221     .9165175    .9780585
              Pr(cwinit=1) |   .0475989     .0163221     .0219415    .0834825

Simqi generated the following new variable(s): max14

. setx p max polity21 15 ppolity 15*.0289596

. simqi, pr genpr(max15)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9562478     .0148043     .9226673    .9797202
              Pr(cwinit=1) |   .0437522     .0148043     .0202798    .0773327

Simqi generated the following new variable(s): max15

. setx p max polity21 16 ppolity 16*.0289596

. simqi, pr genpr(max16)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9597412      .013633     .9288613    .9812117
              Pr(cwinit=1) |   .0402588      .013633     .0187883    .0711387

Simqi generated the following new variable(s): max16

. setx p max polity21 17 ppolity 17*.0289596

. simqi, pr genpr(max17)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9629137     .0127529     .9340933    .9831701
              Pr(cwinit=1) |   .0370863     .0127529     .0168299    .0659067

Simqi generated the following new variable(s): max17

. setx p max polity21 18 ppolity 18*.0289596

. simqi, pr genpr(max18)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9657951     .0121097     .9380058    .9850286
              Pr(cwinit=1) |   .0342049     .0121097     .0149714    .0619941

Simqi generated the following new variable(s): max18

. setx p max polity21 19 ppolity 19*.0289596

. simqi, pr genpr(max19)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9684129     .0116527     .9405321    .9862247
              Pr(cwinit=1) |   .0315871     .0116527     .0137753    .0594679

Simqi generated the following new variable(s): max19

. setx p max polity21 20 ppolity 20*.0289596

. simqi, pr genpr(max20)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9707921     .0113371     .9427851    .9876161
              Pr(cwinit=1) |   .0292079     .0113371     .0123839    .0572149

Simqi generated the following new variable(s): max20

. setx p max polity21 21 ppolity 21*.0289596

. simqi, pr genpr(max21)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9729557     .0111253     .9452938    .9894121
              Pr(cwinit=1) |   .0270443     .0111253     .0105879    .0547062

Simqi generated the following new variable(s): max21

. 
. setx mean

. 
. setx p min polity21 1 ppolity 1*2.39e-18

. simqi, pr genpr(min1)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9995325     .0000502     .9994301    .9996276
              Pr(cwinit=1) |   .0004675     .0000502     .0003724    .0005699

Simqi generated the following new variable(s): min1

. setx p min polity21 2 ppolity 2*2.39e-18

. simqi, pr genpr(min2)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |    .999526     .0000484     .9994278    .9996167
              Pr(cwinit=1) |    .000474     .0000484     .0003833    .0005722

Simqi generated the following new variable(s): min2

. setx p min polity21 3 ppolity 3*2.39e-18

. simqi, pr genpr(min3)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9995193     .0000466     .9994225    .9996052
              Pr(cwinit=1) |   .0004807     .0000466     .0003948    .0005775

Simqi generated the following new variable(s): min3

. setx p min polity21 4 ppolity 4*2.39e-18

. simqi, pr genpr(min4)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9995126      .000045     .9994177    .9995942
              Pr(cwinit=1) |   .0004874      .000045     .0004058    .0005823

Simqi generated the following new variable(s): min4

. setx p min polity21 5 ppolity 5*2.39e-18

. simqi, pr genpr(min5)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9995057     .0000435     .9994142     .999584
              Pr(cwinit=1) |   .0004943     .0000435      .000416    .0005858

Simqi generated the following new variable(s): min5

. setx p min polity21 6 ppolity 6*2.39e-18

. simqi, pr genpr(min6)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994987     .0000421     .9994125    .9995747
              Pr(cwinit=1) |   .0005013     .0000421     .0004253    .0005875

Simqi generated the following new variable(s): min6

. setx p min polity21 7 ppolity 7*2.39e-18

. simqi, pr genpr(min7)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994916     .0000409     .9994096    .9995673
              Pr(cwinit=1) |   .0005084     .0000409     .0004327    .0005904

Simqi generated the following new variable(s): min7

. setx p min polity21 8 ppolity 8*2.39e-18

. simqi, pr genpr(min8)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994843     .0000399      .999405    .9995579
              Pr(cwinit=1) |   .0005157     .0000399     .0004421     .000595

Simqi generated the following new variable(s): min8

. setx p min polity21 9 ppolity 9*2.39e-18

. simqi, pr genpr(min9)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |    .999477     .0000392     .9993998    .9995492
              Pr(cwinit=1) |    .000523     .0000392     .0004508    .0006002

Simqi generated the following new variable(s): min9

. setx p min polity21 10 ppolity 10*2.39e-18

. simqi, pr genpr(min10)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994694     .0000389     .9993928    .9995432
              Pr(cwinit=1) |   .0005306     .0000389     .0004568    .0006072

Simqi generated the following new variable(s): min10

. setx p min polity21 11 ppolity 11*2.39e-18

. simqi, pr genpr(min11)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994618     .0000389     .9993832    .9995363
              Pr(cwinit=1) |   .0005382     .0000389     .0004637    .0006169

Simqi generated the following new variable(s): min11

. setx p min polity21 12 ppolity 12*2.39e-18

. simqi, pr genpr(min12)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |    .999454     .0000392      .999373    .9995278
              Pr(cwinit=1) |    .000546     .0000392     .0004722     .000627

Simqi generated the following new variable(s): min12

. setx p min polity21 13 ppolity 13*2.39e-18

. simqi, pr genpr(min13)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994461       .00004     .9993629    .9995206
              Pr(cwinit=1) |   .0005539       .00004     .0004794    .0006371

Simqi generated the following new variable(s): min13

. setx p min polity21 14 ppolity 14*2.39e-18

. simqi, pr genpr(min14)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |    .999438     .0000413     .9993508     .999516
              Pr(cwinit=1) |    .000562     .0000413     .0004841    .0006493

Simqi generated the following new variable(s): min14

. setx p min polity21 15 ppolity 15*2.39e-18

. simqi, pr genpr(min15)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994298     .0000429     .9993382    .9995109
              Pr(cwinit=1) |   .0005702     .0000429     .0004891    .0006618

Simqi generated the following new variable(s): min15

. setx p min polity21 16 ppolity 16*2.39e-18

. simqi, pr genpr(min16)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994214      .000045     .9993274    .9995053
              Pr(cwinit=1) |   .0005786      .000045     .0004947    .0006726

Simqi generated the following new variable(s): min16

. setx p min polity21 17 ppolity 17*2.39e-18

. simqi, pr genpr(min17)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994128     .0000475     .9993162    .9995024
              Pr(cwinit=1) |   .0005872     .0000475     .0004976    .0006838

Simqi generated the following new variable(s): min17

. setx p min polity21 18 ppolity 18*2.39e-18

. simqi, pr genpr(min18)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9994041     .0000504     .9993031     .999499
              Pr(cwinit=1) |   .0005959     .0000504      .000501    .0006969

Simqi generated the following new variable(s): min18

. setx p min polity21 19 ppolity 19*2.39e-18

. simqi, pr genpr(min19)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9993953     .0000536     .9992852    .9994957
              Pr(cwinit=1) |   .0006047     .0000536     .0005043    .0007148

Simqi generated the following new variable(s): min19

. setx p min polity21 20 ppolity 20*2.39e-18

. simqi, pr genpr(min20)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9993863     .0000572     .9992662    .9994916
              Pr(cwinit=1) |   .0006137     .0000572     .0005084    .0007338

Simqi generated the following new variable(s): min20

. setx p min polity21 21 ppolity 21*2.39e-18

. simqi, pr genpr(min21)

      Quantity of Interest |     Mean       Std. Err.    [95% Conf. Interval]
---------------------------+--------------------------------------------------
              Pr(cwinit=0) |   .9993771     .0000611     .9992454    .9994876
              Pr(cwinit=1) |   .0006229     .0000611     .0005124    .0007546

Simqi generated the following new variable(s): min21

. 
. */ Use this data to generate Figure 3.17 */
. */ Given use of clarify, exact totals will vary each time */
. 
. */ footnote 55 on page 119: Alternate Randomization: Replication of Regression Results For Table 3.1 */
. 
. estimates clear

. clear

. use WhyLeadersFightDyadicReplication.dta, clear

. 
. */ Randomizing on the leader, not the leader year*/
. egen randleadid=group(leaderid)
(45037 missing values generated)

. gen leadodd = mod(randleadid,2)
(45037 missing values generated)

. label variable leadodd "Randomly assigned leaders to 1 or 0"

. 
. logit cwinit milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicine 
> religion activist careerpolitician creative business aristocratlandowner police militarycareer scienceeng bluecollar g
> ender totalspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure10
> 00 leaderpeaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if leadodd==0, robust cluster(leaderid)

note: creative omitted because of collinearity
Iteration 0:   log pseudolikelihood = -7955.7024  
Iteration 1:   log pseudolikelihood =  -7837.799  
Iteration 2:   log pseudolikelihood = -7601.9561  
Iteration 3:   log pseudolikelihood = -7590.7161  
Iteration 4:   log pseudolikelihood =  -7590.213  
Iteration 5:   log pseudolikelihood = -7590.1887  
Iteration 6:   log pseudolikelihood = -7590.1887  

Logistic regression                               Number of obs   =     579930
                                                  Wald chi2(36)   =     178.19
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -7590.1887                 Pseudo R2       =     0.0459

                                   (Std. Err. adjusted for 1085 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .9472069   .3587796     2.64   0.008     .2440119    1.650402
             combat |   .4235687   .2851661     1.49   0.137    -.1353466    .9824839
              rebel |  -.0248549   .2407001    -0.10   0.918    -.4966184    .4469085
             warwin |   .7242556   .2716762     2.67   0.008       .19178    1.256731
            warloss |   .3892029   .3848288     1.01   0.312    -.3650477    1.143454
           rebelwin |   .1642058   .2692059     0.61   0.542    -.3634281    .6918397
          rebelloss |   .7949135    .410363     1.94   0.053    -.0093831     1.59921
           leveledu |  -.0494622   .1246864    -0.40   0.692    -.2938431    .1949187
                age |   .0042782   .0064227     0.67   0.505      -.00831    .0168664
            teacher |   .2258929   .2590047     0.87   0.383    -.2817471    .7335329
         journalism |  -.2080969   .3445617    -0.60   0.546    -.8834255    .4672317
                law |  -.0773434   .2778488    -0.28   0.781     -.621917    .4672302
           medicine |  -.3667011   .3992452    -0.92   0.358    -1.149207    .4158052
           religion |  -1.135084   .5724915    -1.98   0.047    -2.257147   -.0130215
           activist |   .0934368    .197622     0.47   0.636    -.2938952    .4807689
   careerpolitician |   -.131849   .1641711    -0.80   0.422    -.4536184    .1899205
           creative |          0  (omitted)
           business |  -.5988148   .2316834    -2.58   0.010    -1.052906   -.1447236
aristocratlandowner |   -.451184   .5915943    -0.76   0.446    -1.610687    .7083194
             police |  -.4837105   1.195833    -0.40   0.686    -2.827501     1.86008
     militarycareer |  -.5084841    .360522    -1.41   0.158    -1.215094     .198126
         scienceeng |   .4367705   .3412288     1.28   0.201    -.2320256    1.105567
         bluecollar |   .1872155   .3301726     0.57   0.571    -.4599109    .8343418
             gender |   .6014344   .5112623     1.18   0.239    -.4006213     1.60349
       totalspouses |  -.1192401   .0871805    -1.37   0.171    -.2901107    .0516305
            married |  -.1903675   .7888828    -0.24   0.809    -1.736549    1.355814
     marriedinpower |  -.8247424    .577593    -1.43   0.153    -1.956804     .307319
           divorced |   .0095755   .2115857     0.05   0.964    -.4051249    .4242759
         childtotal |   -.003571   .0051397    -0.69   0.487    -.0136445    .0065026
       parstability |   .0891701    .306716     0.29   0.771    -.5119823    .6903224
            illegit |  -.2584244   .3381238    -0.76   0.445    -.9211349    .4042862
            royalty |   .3187448   .5455112     0.58   0.559    -.7504375    1.387927
       orphanbinary |   .2697287   .3114486     0.87   0.386    -.3406992    .8801567
   officetenure1000 |  -.0057004   .0167568    -0.34   0.734    -.0385431    .0271423
    leaderpeaceyrs1 |   .0093847   .0017716     5.30   0.000     .0059124     .012857
    leaderpeaceyrs2 |  -.0131659   .0044746    -2.94   0.003     -.021936   -.0043958
    leaderpeaceyrs3 |   .0121255   .0066261     1.83   0.067    -.0008614    .0251124
              _cons |  -5.884351   .9299547    -6.33   0.000    -7.707029   -4.061673
-------------------------------------------------------------------------------------
Note: 989 failures and 0 successes completely determined.

. 
. predict p
(option pr assumed; Pr(cwinit))
(148178 missing values generated)

. label var p "Predicted Leader Risk Score"

. 
. logit cwinit p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if lea
> dodd==1, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -6906.7549  
Iteration 1:   log pseudolikelihood = -6328.8563  
Iteration 2:   log pseudolikelihood = -5491.5587  
Iteration 3:   log pseudolikelihood = -5468.8426  
Iteration 4:   log pseudolikelihood = -5468.4461  
Iteration 5:   log pseudolikelihood =  -5468.446  

Logistic regression                               Number of obs   =     483297
                                                  Wald chi2(13)   =    1870.92
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood =  -5468.446                 Pseudo R2       =     0.2082

                             (Std. Err. adjusted for 25610 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   68.92992   18.04614     3.82   0.000     33.56013    104.2997
        dem1 |   .1354155   .1183836     1.14   0.253     -.096612     .367443
        dem2 |   .3851228   .1385017     2.78   0.005     .1136645    .6565811
    jointdem |  -.9789399   .2095192    -4.67   0.000     -1.38959   -.5682898
    sideabof |   .5289586   .1543399     3.43   0.001     .2264579    .8314592
     defpact |   .9768174   .3113097     3.14   0.002     .3666616    1.586973
    contigld |   3.314475   .1315886    25.19   0.000     3.056566    3.572384
      syscon |   1.881393   1.122185     1.68   0.094    -.3180499    4.080836
     satisdy |  -1.498814   .5415631    -2.77   0.006    -2.560258   -.4373701
      numGPs |   .1633513   .0510215     3.20   0.001     .0633511    .2633515
   cwpceyrs1 |   .0024438   .0001975    12.37   0.000     .0020567     .002831
   cwpceyrs2 |  -.0018113   .0001564   -11.58   0.000    -.0021178   -.0015048
   cwpceyrs3 |   .0004155   .0000402    10.32   0.000     .0003366    .0004943
       _cons |  -7.301705   .5646735   -12.93   0.000    -8.408445   -6.194965
------------------------------------------------------------------------------

. 
. drop p

. 
. logit cwinit milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicine 
> religion activist careerpolitician creative business aristocratlandowner police militarycareer scienceeng bluecollar g
> ender totalspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure10
> 00 leaderpeaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if leadodd==0, robust cluster(leaderid)

note: creative omitted because of collinearity
Iteration 0:   log pseudolikelihood = -7955.7024  
Iteration 1:   log pseudolikelihood =  -7837.799  
Iteration 2:   log pseudolikelihood = -7601.9561  
Iteration 3:   log pseudolikelihood = -7590.7161  
Iteration 4:   log pseudolikelihood =  -7590.213  
Iteration 5:   log pseudolikelihood = -7590.1887  
Iteration 6:   log pseudolikelihood = -7590.1887  

Logistic regression                               Number of obs   =     579930
                                                  Wald chi2(36)   =     178.19
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -7590.1887                 Pseudo R2       =     0.0459

                                   (Std. Err. adjusted for 1085 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .9472069   .3587796     2.64   0.008     .2440119    1.650402
             combat |   .4235687   .2851661     1.49   0.137    -.1353466    .9824839
              rebel |  -.0248549   .2407001    -0.10   0.918    -.4966184    .4469085
             warwin |   .7242556   .2716762     2.67   0.008       .19178    1.256731
            warloss |   .3892029   .3848288     1.01   0.312    -.3650477    1.143454
           rebelwin |   .1642058   .2692059     0.61   0.542    -.3634281    .6918397
          rebelloss |   .7949135    .410363     1.94   0.053    -.0093831     1.59921
           leveledu |  -.0494622   .1246864    -0.40   0.692    -.2938431    .1949187
                age |   .0042782   .0064227     0.67   0.505      -.00831    .0168664
            teacher |   .2258929   .2590047     0.87   0.383    -.2817471    .7335329
         journalism |  -.2080969   .3445617    -0.60   0.546    -.8834255    .4672317
                law |  -.0773434   .2778488    -0.28   0.781     -.621917    .4672302
           medicine |  -.3667011   .3992452    -0.92   0.358    -1.149207    .4158052
           religion |  -1.135084   .5724915    -1.98   0.047    -2.257147   -.0130215
           activist |   .0934368    .197622     0.47   0.636    -.2938952    .4807689
   careerpolitician |   -.131849   .1641711    -0.80   0.422    -.4536184    .1899205
           creative |          0  (omitted)
           business |  -.5988148   .2316834    -2.58   0.010    -1.052906   -.1447236
aristocratlandowner |   -.451184   .5915943    -0.76   0.446    -1.610687    .7083194
             police |  -.4837105   1.195833    -0.40   0.686    -2.827501     1.86008
     militarycareer |  -.5084841    .360522    -1.41   0.158    -1.215094     .198126
         scienceeng |   .4367705   .3412288     1.28   0.201    -.2320256    1.105567
         bluecollar |   .1872155   .3301726     0.57   0.571    -.4599109    .8343418
             gender |   .6014344   .5112623     1.18   0.239    -.4006213     1.60349
       totalspouses |  -.1192401   .0871805    -1.37   0.171    -.2901107    .0516305
            married |  -.1903675   .7888828    -0.24   0.809    -1.736549    1.355814
     marriedinpower |  -.8247424    .577593    -1.43   0.153    -1.956804     .307319
           divorced |   .0095755   .2115857     0.05   0.964    -.4051249    .4242759
         childtotal |   -.003571   .0051397    -0.69   0.487    -.0136445    .0065026
       parstability |   .0891701    .306716     0.29   0.771    -.5119823    .6903224
            illegit |  -.2584244   .3381238    -0.76   0.445    -.9211349    .4042862
            royalty |   .3187448   .5455112     0.58   0.559    -.7504375    1.387927
       orphanbinary |   .2697287   .3114486     0.87   0.386    -.3406992    .8801567
   officetenure1000 |  -.0057004   .0167568    -0.34   0.734    -.0385431    .0271423
    leaderpeaceyrs1 |   .0093847   .0017716     5.30   0.000     .0059124     .012857
    leaderpeaceyrs2 |  -.0131659   .0044746    -2.94   0.003     -.021936   -.0043958
    leaderpeaceyrs3 |   .0121255   .0066261     1.83   0.067    -.0008614    .0251124
              _cons |  -5.884351   .9299547    -6.33   0.000    -7.707029   -4.061673
-------------------------------------------------------------------------------------
Note: 989 failures and 0 successes completely determined.

. 
. predict p
(option pr assumed; Pr(cwinit))
(148178 missing values generated)

. label var p "Predicted Leader Risk Score"

. 
. logit cwinit p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if lea
> dodd==1, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -6906.7549  
Iteration 1:   log pseudolikelihood = -6328.8563  
Iteration 2:   log pseudolikelihood = -5491.5587  
Iteration 3:   log pseudolikelihood = -5468.8426  
Iteration 4:   log pseudolikelihood = -5468.4461  
Iteration 5:   log pseudolikelihood =  -5468.446  

Logistic regression                               Number of obs   =     483297
                                                  Wald chi2(13)   =    1870.92
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood =  -5468.446                 Pseudo R2       =     0.2082

                             (Std. Err. adjusted for 25610 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   68.92992   18.04614     3.82   0.000     33.56013    104.2997
        dem1 |   .1354155   .1183836     1.14   0.253     -.096612     .367443
        dem2 |   .3851228   .1385017     2.78   0.005     .1136645    .6565811
    jointdem |  -.9789399   .2095192    -4.67   0.000     -1.38959   -.5682898
    sideabof |   .5289586   .1543399     3.43   0.001     .2264579    .8314592
     defpact |   .9768174   .3113097     3.14   0.002     .3666616    1.586973
    contigld |   3.314475   .1315886    25.19   0.000     3.056566    3.572384
      syscon |   1.881393   1.122185     1.68   0.094    -.3180499    4.080836
     satisdy |  -1.498814   .5415631    -2.77   0.006    -2.560258   -.4373701
      numGPs |   .1633513   .0510215     3.20   0.001     .0633511    .2633515
   cwpceyrs1 |   .0024438   .0001975    12.37   0.000     .0020567     .002831
   cwpceyrs2 |  -.0018113   .0001564   -11.58   0.000    -.0021178   -.0015048
   cwpceyrs3 |   .0004155   .0000402    10.32   0.000     .0003366    .0004943
       _cons |  -7.301705   .5646735   -12.93   0.000    -8.408445   -6.194965
------------------------------------------------------------------------------

. 
. drop p

. 
. */ Randomizing on the country, not the leader year */
. logit cwinit milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicine 
> religion activist careerpolitician business aristocratlandowner police militarycareer scienceeng bluecollar gender tot
> alspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure1000 leader
> peaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if countryrandom==1, robust cluster(leaderid)

Iteration 0:   log pseudolikelihood = -9298.8028  
Iteration 1:   log pseudolikelihood =  -9180.415  
Iteration 2:   log pseudolikelihood = -8831.8476  
Iteration 3:   log pseudolikelihood = -8816.7644  
Iteration 4:   log pseudolikelihood = -8816.3469  
Iteration 5:   log pseudolikelihood =  -8816.329  
Iteration 6:   log pseudolikelihood = -8816.3289  

Logistic regression                               Number of obs   =     554904
                                                  Wald chi2(36)   =     178.99
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -8816.3289                 Pseudo R2       =     0.0519

                                   (Std. Err. adjusted for 1020 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .6855393   .2503576     2.74   0.006     .1948474    1.176231
             combat |   .3471237   .2713139     1.28   0.201    -.1846417    .8788891
              rebel |  -.3531018   .3403957    -1.04   0.300    -1.020265    .3140616
             warwin |   .8164068   .3019587     2.70   0.007     .2245786    1.408235
            warloss |   .2389283    .399132     0.60   0.549    -.5433562    1.021213
           rebelwin |   .1030577   .2902411     0.36   0.723    -.4658045    .6719199
          rebelloss |   .9492003   .3720156     2.55   0.011     .2200631    1.678338
           leveledu |  -.0302447   .1077723    -0.28   0.779    -.2414745    .1809852
                age |   .0170356   .0069958     2.44   0.015     .0033241     .030747
            teacher |   .2433036    .229845     1.06   0.290    -.2071844    .6937915
         journalism |  -.0983458   .3542937    -0.28   0.781    -.7927486     .596057
                law |   -.261174    .245517    -1.06   0.287    -.7423785    .2200306
           medicine |  -1.074454    .486763    -2.21   0.027    -2.028492   -.1204158
           religion |   1.311398   .5202332     2.52   0.012     .2917596    2.331036
           activist |   .1669096   .2038935     0.82   0.413    -.2327144    .5665335
   careerpolitician |  -.4421272   .1700037    -2.60   0.009    -.7753283    -.108926
           business |  -.4455832   .2165483    -2.06   0.040    -.8700101   -.0211563
aristocratlandowner |  -.4352673   .4373543    -1.00   0.320    -1.292466    .4219313
             police |  -.0633338   .5066025    -0.13   0.901    -1.056256    .9295888
     militarycareer |  -.4225428    .310372    -1.36   0.173    -1.030861    .1857752
         scienceeng |  -.0975292    .303804    -0.32   0.748    -.6929741    .4979158
         bluecollar |  -.0526675   .2729131    -0.19   0.847    -.5875673    .4822324
             gender |   .4928888   .3873395     1.27   0.203    -.2662825     1.25206
       totalspouses |  -.0256424   .0247806    -1.03   0.301    -.0742115    .0229267
            married |   .3039501    .825198     0.37   0.713    -1.313408    1.921309
     marriedinpower |  -.7276249   .3776352    -1.93   0.054    -1.467776    .0125265
           divorced |  -.3265368   .2029196    -1.61   0.108    -.7242519    .0711783
         childtotal |   -.001644   .0045071    -0.36   0.715    -.0104777    .0071897
       parstability |   .2076904   .3089155     0.67   0.501    -.3977728    .8131536
            illegit |  -.4590256    .403883    -1.14   0.256    -1.250622    .3325704
            royalty |   .2100481   .4091092     0.51   0.608    -.5917912    1.011887
       orphanbinary |   .1573479   .3357567     0.47   0.639    -.5007232     .815419
   officetenure1000 |   .0068698   .0153247     0.45   0.654     -.023166    .0369056
    leaderpeaceyrs1 |    .008589    .001534     5.60   0.000     .0055823    .0115957
    leaderpeaceyrs2 |  -.0114537   .0034178    -3.35   0.001    -.0181525    -.004755
    leaderpeaceyrs3 |    .009916    .004795     2.07   0.039     .0005179    .0193141
              _cons |  -6.741468   1.038341    -6.49   0.000    -8.776579   -4.706356
-------------------------------------------------------------------------------------
Note: 252 failures and 0 successes completely determined.

. 
. predict p
(option pr assumed; Pr(cwinit))
(148178 missing values generated)

. label var p "Predicted Leader Risk Score"

. 
. logit cwinit p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if cou
> ntryrandom==0, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood =  -5670.641  
Iteration 1:   log pseudolikelihood = -4778.6249  
Iteration 2:   log pseudolikelihood = -4480.3596  
Iteration 3:   log pseudolikelihood = -4417.4551  
Iteration 4:   log pseudolikelihood = -4416.3983  
Iteration 5:   log pseudolikelihood = -4416.3969  
Iteration 6:   log pseudolikelihood = -4416.3969  

Logistic regression                               Number of obs   =     512406
                                                  Wald chi2(13)   =    1592.55
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -4416.3969                 Pseudo R2       =     0.2212

                             (Std. Err. adjusted for 13900 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   44.92814   17.70188     2.54   0.011     10.23309     79.6232
        dem1 |   .1242292   .1600982     0.78   0.438    -.1895575     .438016
        dem2 |   .4820695   .1856629     2.60   0.009     .1181768    .8459621
    jointdem |  -.8873489   .2569861    -3.45   0.001    -1.391032   -.3836654
    sideabof |   .2237972   .2084457     1.07   0.283     -.184749    .6323433
     defpact |   1.277773   .4925248     2.59   0.009     .3124417    2.243104
    contigld |   3.602514   .1844147    19.53   0.000     3.241068     3.96396
      syscon |   2.390112   1.384594     1.73   0.084    -.3236423    5.103866
     satisdy |  -1.945834   .8299529    -2.34   0.019    -3.572511   -.3191558
      numGPs |   .0556042   .0666115     0.83   0.404    -.0749519    .1861603
   cwpceyrs1 |   .0027918   .0002531    11.03   0.000     .0022957    .0032879
   cwpceyrs2 |  -.0021069   .0002047   -10.29   0.000    -.0025081   -.0017058
   cwpceyrs3 |   .0004999   .0000549     9.10   0.000     .0003923    .0006076
       _cons |  -6.683829   .6575166   -10.17   0.000    -7.972538    -5.39512
------------------------------------------------------------------------------

. 
. drop p

. 
. logit cwinit milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicine 
> religion activist careerpolitician business aristocratlandowner police militarycareer scienceeng bluecollar gender tot
> alspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure1000 leader
> peaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if countryrandom==0, robust cluster(leaderid)

Iteration 0:   log pseudolikelihood = -6048.6964  
Iteration 1:   log pseudolikelihood = -5911.6015  
Iteration 2:   log pseudolikelihood =  -5869.452  
Iteration 3:   log pseudolikelihood = -5866.1021  
Iteration 4:   log pseudolikelihood =  -5864.101  
Iteration 5:   log pseudolikelihood = -5863.6056  
Iteration 6:   log pseudolikelihood =  -5863.585  
Iteration 7:   log pseudolikelihood =  -5863.585  

Logistic regression                               Number of obs   =     575286
                                                  Wald chi2(36)   =     197.95
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood =  -5863.585                 Pseudo R2       =     0.0306

                                   (Std. Err. adjusted for 1151 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .6592516   .3972532     1.66   0.097    -.1193505    1.437854
             combat |   .3029958   .2446819     1.24   0.216    -.1765719    .7825636
              rebel |    .476839   .1479583     3.22   0.001     .1868461    .7668319
             warwin |   .4748145   .2092888     2.27   0.023      .064616    .8850129
            warloss |   .4463243   .1877151     2.38   0.017     .0784095    .8142391
           rebelwin |   .1587989   .2015747     0.79   0.431    -.2362803     .553878
          rebelloss |   .1480665   .4400364     0.34   0.737     -.714389    1.010522
           leveledu |  -.0368465    .097799    -0.38   0.706    -.2285289    .1548359
                age |   .0010316   .0054679     0.19   0.850    -.0096852    .0117485
            teacher |  -.0750409   .1991772    -0.38   0.706    -.4654212    .3153393
         journalism |   .0460924   .2682926     0.17   0.864    -.4797515    .5719362
                law |   .3126589   .1804651     1.73   0.083    -.0410463    .6663641
           medicine |    .249226   .2932521     0.85   0.395    -.3255376    .8239896
           religion |   -.582586   .2618691    -2.22   0.026     -1.09584   -.0693321
           activist |   .3369335   .1670047     2.02   0.044     .0096104    .6642567
   careerpolitician |   .2165099   .1447647     1.50   0.135    -.0672237    .5002434
           business |  -.1751448   .2145941    -0.82   0.414    -.5957415    .2454518
aristocratlandowner |   .5097731   .3945852     1.29   0.196    -.2635998    1.283146
             police |  -.4182045   .6172523    -0.68   0.498    -1.627997    .7915878
     militarycareer |  -.1103146   .3371912    -0.33   0.744    -.7711971     .550568
         scienceeng |  -.1196363   .3415908    -0.35   0.726     -.789142    .5498695
         bluecollar |   -.182343   .2610435    -0.70   0.485     -.693979    .3292929
             gender |  -1.094705   .4998679    -2.19   0.029    -2.074428   -.1149817
       totalspouses |  -.2323473   .1925381    -1.21   0.228    -.6097151    .1450205
            married |  -1.085818   .4423304    -2.45   0.014    -1.952769   -.2188661
     marriedinpower |   .4363079   .3524052     1.24   0.216    -.2543936    1.127009
           divorced |  -.1193222   .1600903    -0.75   0.456    -.4330933     .194449
         childtotal |    .014635   .0162184     0.90   0.367    -.0171525    .0464225
       parstability |   .2230182   .2369335     0.94   0.347    -.2413629    .6873993
            illegit |  -.3732076   .3146212    -1.19   0.236    -.9898538    .2434385
            royalty |    .242656   .3582705     0.68   0.498    -.4595413    .9448533
       orphanbinary |  -.4712638   .3806166    -1.24   0.216    -1.217259    .2747311
   officetenure1000 |  -.0095711   .0173319    -0.55   0.581    -.0435411    .0243989
    leaderpeaceyrs1 |   .0072375    .001288     5.62   0.000     .0047131    .0097618
    leaderpeaceyrs2 |  -.0184318   .0053059    -3.47   0.001    -.0288311   -.0080325
    leaderpeaceyrs3 |   .0264151   .0094849     2.78   0.005     .0078251    .0450051
              _cons |  -5.138456   .7047056    -7.29   0.000    -6.519654   -3.757259
-------------------------------------------------------------------------------------
Note: 3329 failures and 0 successes completely determined.

. 
. predict p
(option pr assumed; Pr(cwinit))
(148178 missing values generated)

. label var p "Predicted Leader Risk Score"

. 
. logit cwinit p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if cou
> ntryrandom==1, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood =  -8637.215  
Iteration 1:   log pseudolikelihood = -7448.9159  
Iteration 2:   log pseudolikelihood = -6873.2707  
Iteration 3:   log pseudolikelihood =    -6870.7  
Iteration 4:   log pseudolikelihood = -6870.6953  
Iteration 5:   log pseudolikelihood = -6870.6953  

Logistic regression                               Number of obs   =     477000
                                                  Wald chi2(13)   =    2052.10
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -6870.6953                 Pseudo R2       =     0.2045

                             (Std. Err. adjusted for 13688 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   84.91294   16.01843     5.30   0.000     53.51739    116.3085
        dem1 |    .389727   .1295947     3.01   0.003     .1357262    .6437279
        dem2 |   .5894572   .1365078     4.32   0.000     .3219069    .8570076
    jointdem |  -1.042223   .2058278    -5.06   0.000    -1.445637   -.6388075
    sideabof |   .8347761   .1542868     5.41   0.000     .5323795    1.137173
     defpact |   1.300367   .2928425     4.44   0.000     .7264061    1.874328
    contigld |    3.11941   .1291447    24.15   0.000     2.866291    3.372529
      syscon |   2.689677   1.051414     2.56   0.011      .628944    4.750409
     satisdy |  -2.454267   .5088305    -4.82   0.000    -3.451556   -1.456977
      numGPs |   .2722568   .0480941     5.66   0.000      .177994    .3665196
   cwpceyrs1 |   .0024427   .0001828    13.36   0.000     .0020844    .0028011
   cwpceyrs2 |  -.0017924   .0001423   -12.59   0.000    -.0020714   -.0015135
   cwpceyrs3 |   .0004038   .0000355    11.36   0.000     .0003341    .0004734
       _cons |  -7.702257   .5962429   -12.92   0.000    -8.870872   -6.533643
------------------------------------------------------------------------------

. 
. drop p

. 
. */ footnote 56 on page 120: Stepwise Regression and replication of Table 3.1 */
. 
. estimates clear

. clear

. use WhyLeadersFightDyadicReplication.dta, clear

. 
. */ For illustration purposes, here is one 'run' of a stepwise model to show what it selects: see the accompanying note
>  for more on the methodology */
. stepwise, pr(.20): logit cwinit milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journ
> alism law medicine religion activist careerpolitician creative business aristocratlandowner police militarycareer scie
> nceeng bluecollar gender totalspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbi
> nary officetenure1000 leaderpeaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3
                      begin with full model
p = 0.9548 >= 0.2000  removing police
p = 0.9493 >= 0.2000  removing officetenure1000
p = 0.8973 >= 0.2000  removing journalism
p = 0.8795 >= 0.2000  removing orphanbinary
p = 0.5469 >= 0.2000  removing leveledu
p = 0.5126 >= 0.2000  removing scienceeng
p = 0.5054 >= 0.2000  removing rebel
p = 0.4682 >= 0.2000  removing childtotal
p = 0.3912 >= 0.2000  removing creative
p = 0.3376 >= 0.2000  removing bluecollar
p = 0.3148 >= 0.2000  removing gender
p = 0.3445 >= 0.2000  removing married

Logistic regression                               Number of obs   =    1130190
                                                  LR chi2(25)     =    1068.92
                                                  Prob > chi2     =     0.0000
Log likelihood = -14888.172                       Pseudo R2       =     0.0347

-------------------------------------------------------------------------------------
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .6642636   .0771824     8.61   0.000     .5129888    .8155383
             combat |   .3710787   .0855356     4.34   0.000     .2034321    .5387253
            illegit |  -.3907209    .147385    -2.65   0.008    -.6795903   -.1018516
             warwin |    .737083   .0851518     8.66   0.000     .5701886    .9039774
            warloss |   .2977839   .0894494     3.33   0.001     .1224663    .4731016
           rebelwin |   .1936904   .0770112     2.52   0.012     .0427513    .3446296
          rebelloss |   .7429791   .1030185     7.21   0.000     .5410665    .9448918
    leaderpeaceyrs2 |  -.0129672   .0021583    -6.01   0.000    -.0171974    -.008737
                age |   .0139331   .0020121     6.92   0.000     .0099895    .0178768
            teacher |    .180328   .0615901     2.93   0.003     .0596137    .3010423
    leaderpeaceyrs1 |   .0080456   .0007603    10.58   0.000     .0065555    .0095357
                law |  -.1358466   .0597897    -2.27   0.023    -.2530323   -.0186609
           medicine |  -.5434694    .165223    -3.29   0.001    -.8673005   -.2196382
           religion |   .7125036   .1183223     6.02   0.000     .4805962     .944411
           activist |   .2257527   .0574684     3.93   0.000     .1131167    .3383886
   careerpolitician |  -.1862841    .051951    -3.59   0.000    -.2881062    -.084462
       parstability |   .2764242   .0885834     3.12   0.002     .1028039    .4500444
           business |   -.335814   .0853387    -3.94   0.000    -.5030747   -.1685532
aristocratlandowner |  -.2272347   .1149048    -1.98   0.048     -.452444   -.0020255
    leaderpeaceyrs3 |   .0138058   .0033588     4.11   0.000     .0072226     .020389
     militarycareer |  -.4339197    .073005    -5.94   0.000     -.577007   -.2908324
            royalty |    .324404    .104647     3.10   0.002     .1192997    .5295083
           divorced |  -.1983778   .0654151    -3.03   0.002    -.3265891   -.0701665
     marriedinpower |  -.4510307   .0716619    -6.29   0.000    -.5914855    -.310576
       totalspouses |  -.0262122   .0168006    -1.56   0.119    -.0591408    .0067164
              _cons |  -6.591586    .142116   -46.38   0.000    -6.870128   -6.313044
-------------------------------------------------------------------------------------
Note: 2366 failures and 0 successes completely determined.

. 
. logit cwinit milnoncombat combat royalty warwin warloss rebelwin rebelloss age teacher law medicine religion activist 
> careerpolitician parstability business aristocratlandowner militarycareer illegit divorced marriedinpower totalspouses
>  leaderpeaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if random==1, robust cluster(leaderid)

Iteration 0:   log pseudolikelihood = -7917.8353  
Iteration 1:   log pseudolikelihood = -7822.6039  
Iteration 2:   log pseudolikelihood = -7646.8623  
Iteration 3:   log pseudolikelihood = -7640.0547  
Iteration 4:   log pseudolikelihood =  -7639.108  
Iteration 5:   log pseudolikelihood = -7638.9659  
Iteration 6:   log pseudolikelihood = -7638.9641  
Iteration 7:   log pseudolikelihood = -7638.9641  

Logistic regression                               Number of obs   =     603852
                                                  Wald chi2(25)   =     188.77
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -7638.9641                 Pseudo R2       =     0.0352

                                   (Std. Err. adjusted for 2212 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .6285216    .274952     2.29   0.022     .0896257    1.167418
             combat |   .3453834   .1987344     1.74   0.082    -.0441289    .7348957
            royalty |   .3894806   .3479635     1.12   0.263    -.2925152    1.071476
             warwin |   .8456861   .2115935     4.00   0.000     .4309704    1.260402
            warloss |    .234295   .2357927     0.99   0.320    -.2278503    .6964402
           rebelwin |   .3132231   .1886982     1.66   0.097    -.0566185    .6830647
          rebelloss |   .7523924   .2633114     2.86   0.004     .2363114    1.268473
                age |   .0120624   .0069617     1.73   0.083    -.0015823    .0257071
            teacher |   .1826308   .2103327     0.87   0.385    -.2296136    .5948753
                law |  -.0542704   .1817812    -0.30   0.765     -.410555    .3020142
           medicine |  -.4781549   .2544785    -1.88   0.060    -.9769236    .0206138
           religion |   .6010529   .7483412     0.80   0.422    -.8656689    2.067775
           activist |   .2249316   .1743359     1.29   0.197    -.1167604    .5666236
   careerpolitician |  -.0733848   .1403981    -0.52   0.601    -.3485601    .2017905
       parstability |    .451562   .2184309     2.07   0.039     .0234452    .8796787
           business |  -.2015688    .173511    -1.16   0.245    -.5416441    .1385066
aristocratlandowner |  -.1555472   .4018332    -0.39   0.699    -.9431257    .6320313
     militarycareer |  -.4117682   .2410396    -1.71   0.088    -.8841972    .0606608
            illegit |  -.3517603   .2910814    -1.21   0.227    -.9222694    .2187489
           divorced |  -.1690332   .1459764    -1.16   0.247    -.4551418    .1170753
     marriedinpower |  -.4348661   .3047367    -1.43   0.154    -1.032139    .1624068
       totalspouses |  -.0223756   .0333205    -0.67   0.502    -.0876826    .0429314
    leaderpeaceyrs1 |   .0081819   .0014656     5.58   0.000     .0053093    .0110545
    leaderpeaceyrs2 |  -.0138837   .0047346    -2.93   0.003    -.0231632   -.0046041
    leaderpeaceyrs3 |   .0156404   .0080318     1.95   0.051    -.0001016    .0313824
              _cons |  -6.657728   .5722736   -11.63   0.000    -7.779364   -5.536092
-------------------------------------------------------------------------------------
Note: 2044 failures and 0 successes completely determined.

. 
. predict p
(option pr assumed; Pr(cwinit))
(70461 missing values generated)

. label var p "Predicted Leader Risk Score"

. 
. drop if random==1
(638994 observations deleted)

. 
. logit cwinit p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if ran
> dom==0, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -7303.5185  
Iteration 1:   log pseudolikelihood =  -6609.952  
Iteration 2:   log pseudolikelihood =  -5705.645  
Iteration 3:   log pseudolikelihood =  -5684.367  
Iteration 4:   log pseudolikelihood = -5684.1092  
Iteration 5:   log pseudolikelihood = -5684.1092  

Logistic regression                               Number of obs   =     507675
                                                  Wald chi2(13)   =    2625.83
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -5684.1092                 Pseudo R2       =     0.2217

                             (Std. Err. adjusted for 27501 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   166.2018   13.14693    12.64   0.000     140.4343    191.9693
        dem1 |   .4490525   .1230348     3.65   0.000     .2079087    .6901963
        dem2 |   .7097394   .1300256     5.46   0.000     .4548938    .9645849
    jointdem |  -1.228124   .2116032    -5.80   0.000    -1.642859   -.8133899
    sideabof |   .3867009   .1447071     2.67   0.008     .1030801    .6703217
     defpact |    1.21154    .310284     3.90   0.000     .6033942    1.819685
    contigld |   3.272095   .1206514    27.12   0.000     3.035623    3.508568
      syscon |   2.262419   1.000831     2.26   0.024      .300827    4.224011
     satisdy |  -1.917061   .5511129    -3.48   0.001    -2.997223   -.8368998
      numGPs |   .2004203   .0468853     4.27   0.000     .1085268    .2923137
   cwpceyrs1 |   .0025522   .0001931    13.22   0.000     .0021738    .0029307
   cwpceyrs2 |  -.0018712   .0001523   -12.28   0.000    -.0021698   -.0015727
   cwpceyrs3 |   .0004211    .000039    10.80   0.000     .0003447    .0004975
       _cons |  -7.637506   .5216147   -14.64   0.000    -8.659852    -6.61516
------------------------------------------------------------------------------

. 
. margins, atmeans vsquish

Adjusted predictions                              Number of obs   =     507675
Model VCE    : Robust

Expression   : Pr(cwinit), predict()
at           : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
       _cons |   .0006847   .0000452    15.15   0.000     .0005961    .0007733
------------------------------------------------------------------------------

. margins, atmeans at((p10)syscon) at((p90) syscon) at(contigld=0) at(contigld=1) at(dem1=1 dem2=1 jointdem=1) at((p10)s
> atisdy) at((p90)satisdy) at((p10)numGPs) at((p90)numGPs) at(defpact=0) at(defpact=1) at((p10)sideabof) at((p90)sideabo
> f) at((p10)p) at((p90)p) vsquish

Adjusted predictions                              Number of obs   =     507675
Model VCE    : Robust

Expression   : Pr(cwinit), predict()
1._at        : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =      .22651 (p10)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
2._at        : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =     .326193 (p90)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
3._at        : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =           0
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
4._at        : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =           1
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
5._at        : p               =    .0018321 (mean)
               dem1            =           1
               dem2            =           1
               jointdem        =           1
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
6._at        : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =      .33902 (p10)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
7._at        : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =     .516265 (p90)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
8._at        : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =           5 (p10)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
9._at        : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =           7 (p90)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
10._at       : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =           0
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
11._at       : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =           1
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
12._at       : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .0348985 (p10)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
13._at       : p               =    .0018321 (mean)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .9655887 (p90)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
14._at       : p               =    .0003037 (p10)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)
15._at       : p               =    .0034559 (p90)
               dem1            =    .2981593 (mean)
               dem2            =    .2957305 (mean)
               jointdem        =    .0924942 (mean)
               sideabof        =    .5009451 (mean)
               defpact         =     .053028 (mean)
               contigld        =    .0282878 (mean)
               syscon          =    .2724179 (mean)
               satisdy         =    .4690281 (mean)
               numGPs          =    5.741898 (mean)
               cwpceyrs1       =   -16294.39 (mean)
               cwpceyrs2       =   -31572.81 (mean)
               cwpceyrs3       =    -44864.5 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
         _at |
          1  |   .0006172   .0000466    13.25   0.000     .0005259    .0007085
          2  |   .0007732   .0000698    11.07   0.000     .0006364    .0009101
          3  |   .0006242   .0000423    14.74   0.000     .0005413    .0007072
          4  |   .0162022   .0016127    10.05   0.000     .0130413     .019363
          5  |   .0005076   .0000802     6.33   0.000     .0003504    .0006647
          6  |   .0008784   .0000784    11.20   0.000     .0007247     .001032
          7  |   .0006255   .0000468    13.38   0.000     .0005338    .0007171
          8  |   .0005902   .0000427    13.82   0.000     .0005065    .0006739
          9  |   .0008809   .0000807    10.92   0.000     .0007227    .0010391
         10  |   .0006421   .0000447    14.36   0.000     .0005545    .0007298
         11  |   .0021535   .0006331     3.40   0.001     .0009126    .0033944
         12  |   .0005719   .0000564    10.13   0.000     .0004612    .0006825
         13  |   .0008194   .0000734    11.16   0.000     .0006754    .0009633
         14  |   .0005312   .0000367    14.47   0.000     .0004593    .0006031
         15  |   .0008967   .0000621    14.43   0.000     .0007749    .0010184
------------------------------------------------------------------------------

. 
. */ REPLICATION OF TABLE 3.1 AND FIGURE 3.14 WITH UPDATED DATASET */
. 
. estimates clear

. clear

. use WhyLeadersFightDyadicReplication_updated.dta, clear

. 
. */ Table 3.1 */
. */ Uses leader peace year splines, not country peace year splines, as per footnote 57 on page 120 */
. 
. logit cwinit milnoncombat combat rebel warwin warloss rebelwin rebelloss leveledu age teacher journalism law medicine 
> religion activist careerpolitician creative business aristocratlandowner police militarycareer scienceeng bluecollar g
> ender totalspouses married marriedinpower divorced childtotal parstability illegit royalty orphanbinary officetenure10
> 00 leaderpeaceyrs1 leaderpeaceyrs2 leaderpeaceyrs3 if random==1, robust cluster(leaderid)

Iteration 0:   log pseudolikelihood = -7149.1202  
Iteration 1:   log pseudolikelihood = -7069.4631  
Iteration 2:   log pseudolikelihood = -6898.4433  
Iteration 3:   log pseudolikelihood =  -6892.112  
Iteration 4:   log pseudolikelihood = -6891.1728  
Iteration 5:   log pseudolikelihood = -6891.0444  
Iteration 6:   log pseudolikelihood = -6891.0433  
Iteration 7:   log pseudolikelihood = -6891.0433  

Logistic regression                               Number of obs   =     489560
                                                  Wald chi2(37)   =     190.89
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -6891.0433                 Pseudo R2       =     0.0361

                                   (Std. Err. adjusted for 1828 clusters in leaderid)
-------------------------------------------------------------------------------------
                    |               Robust
             cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
--------------------+----------------------------------------------------------------
       milnoncombat |   .6442872   .2811553     2.29   0.022     .0932329    1.195341
             combat |   .3507683   .2192692     1.60   0.110    -.0789914    .7805281
              rebel |   .0213164   .2305999     0.09   0.926    -.4306511    .4732838
             warwin |   .7360106   .2273291     3.24   0.001     .2904538    1.181567
            warloss |   .2211214    .258667     0.85   0.393    -.2858566    .7280993
           rebelwin |   .3231301   .2029535     1.59   0.111    -.0746515    .7209116
          rebelloss |   .7678402   .3004132     2.56   0.011     .1790411    1.356639
           leveledu |  -.0743646   .0908951    -0.82   0.413    -.2525158    .1037865
                age |   .0107352   .0069263     1.55   0.121    -.0028401    .0243105
            teacher |   .2545674   .2119899     1.20   0.230    -.1609252    .6700599
         journalism |   .0468895   .3692232     0.13   0.899    -.6767747    .7705536
                law |  -.0637396   .2052439    -0.31   0.756    -.4660103    .3385311
           medicine |   -.376992   .2842757    -1.33   0.185    -.9341621    .1801781
           religion |   .8629392   .6927193     1.25   0.213    -.4947656    2.220644
           activist |   .1968296   .1678252     1.17   0.241    -.1321018     .525761
   careerpolitician |   .0202025   .1448178     0.14   0.889    -.2636352    .3040402
           creative |   .5965143   .4769982     1.25   0.211    -.3383849    1.531414
           business |  -.2542477   .1866669    -1.36   0.173    -.6201081    .1116126
aristocratlandowner |  -.2810647   .4616394    -0.61   0.543    -1.185861    .6237319
             police |   .3788169   .4925166     0.77   0.442    -.5864979    1.344132
     militarycareer |  -.4203825   .2989133    -1.41   0.160    -1.006242    .1654768
         scienceeng |   .0919797   .2800364     0.33   0.743    -.4568816    .6408409
         bluecollar |  -.0012514   .2358568    -0.01   0.996    -.4635221    .4610194
             gender |    .462077    .387048     1.19   0.233    -.2965231    1.220677
       totalspouses |  -.0083419   .0762285    -0.11   0.913     -.157747    .1410631
            married |   .2145064   .6055679     0.35   0.723    -.9723849    1.401398
     marriedinpower |  -.5527197   .3510114    -1.57   0.115    -1.240689      .13525
           divorced |  -.2554335   .1566766    -1.63   0.103    -.5625139    .0516469
         childtotal |     .00625   .0179376     0.35   0.728     -.028907     .041407
       parstability |    .409779   .2188754     1.87   0.061    -.0192088    .8387669
            illegit |  -.3884696   .3030979    -1.28   0.200    -.9825307    .2055914
            royalty |   .3426888   .4031938     0.85   0.395    -.4475565    1.132934
       orphanbinary |  -.0964088   .2928879    -0.33   0.742    -.6704586    .4776411
   officetenure1000 |   .0125628   .0132042     0.95   0.341     -.013317    .0384426
    leaderpeaceyrs1 |   .0084474   .0016067     5.26   0.000     .0052984    .0115965
    leaderpeaceyrs2 |  -.0149026   .0053998    -2.76   0.006     -.025486   -.0043191
    leaderpeaceyrs3 |   .0172445   .0092388     1.87   0.062    -.0008632    .0353522
              _cons |   -6.96727   .8668463    -8.04   0.000    -8.666257   -5.268282
-------------------------------------------------------------------------------------
Note: 1580 failures and 0 successes completely determined.

. estimates store m1

. 
. predict p
(option pr assumed; Pr(cwinit))
(298995 missing values generated)

. label var p "Predicted Leader Risk Score"

. 
. drop if random==1
(638994 observations deleted)

. 
. logit cwinit p dem1 dem2 jointdem sideabof defpact contigld syscon satisdy numGPs cwpceyrs1 cwpceyrs2 cwpceyrs3 if ran
> dom==0, robust cluster(dyadid)

Iteration 0:   log pseudolikelihood = -6634.6182  
Iteration 1:   log pseudolikelihood = -5906.4447  
Iteration 2:   log pseudolikelihood = -5185.4592  
Iteration 3:   log pseudolikelihood = -5173.3739  
Iteration 4:   log pseudolikelihood = -5173.2878  
Iteration 5:   log pseudolikelihood = -5173.2878  

Logistic regression                               Number of obs   =     426636
                                                  Wald chi2(13)   =    2317.90
                                                  Prob > chi2     =     0.0000
Log pseudolikelihood = -5173.2878                 Pseudo R2       =     0.2203

                             (Std. Err. adjusted for 26025 clusters in dyadid)
------------------------------------------------------------------------------
             |               Robust
      cwinit |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
           p |   170.5463   12.96282    13.16   0.000     145.1397     195.953
        dem1 |    .454222     .12409     3.66   0.000       .21101     .697434
        dem2 |   .7347712   .1345632     5.46   0.000     .4710321    .9985103
    jointdem |   -1.23279   .2133208    -5.78   0.000    -1.650891   -.8146887
    sideabof |   .2721428   .1514075     1.80   0.072    -.0246103     .568896
     defpact |    1.14069   .3194515     3.57   0.000     .5145763    1.766803
    contigld |    3.20264   .1234588    25.94   0.000     2.960665    3.444615
      syscon |   2.314114    1.00255     2.31   0.021     .3491526    4.279076
     satisdy |  -1.848865   .5664456    -3.26   0.001    -2.959078   -.7386525
      numGPs |    .197087   .0485089     4.06   0.000     .1020113    .2921628
   cwpceyrs1 |   .0025184   .0001984    12.70   0.000     .0021296    .0029072
   cwpceyrs2 |  -.0018396    .000156   -11.79   0.000    -.0021453   -.0015338
   cwpceyrs3 |   .0004113   .0000397    10.36   0.000     .0003335    .0004891
       _cons |  -7.556887   .5405522   -13.98   0.000     -8.61635   -6.497424
------------------------------------------------------------------------------

. estimates store m2

. 
. margins, atmeans vsquish

Adjusted predictions                              Number of obs   =     426636
Model VCE    : Robust

Expression   : Pr(cwinit), predict()
at           : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
       _cons |   .0007591   .0000512    14.84   0.000     .0006589    .0008594
------------------------------------------------------------------------------

. margins, atmeans at((p10)syscon) at((p90) syscon) at(contigld=0) at(contigld=1) at(dem1=1 dem2=1 jointdem=1) at((p10)s
> atisdy) at((p90)satisdy) at((p10)numGPs) at((p90)numGPs) at(defpact=0) at(defpact=1) at((p10)sideabof) at((p90)sideabo
> f) at((p10)p) at((p90)p) vsquish

Adjusted predictions                              Number of obs   =     426636
Model VCE    : Robust

Expression   : Pr(cwinit), predict()
1._at        : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =      .22651 (p10)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
2._at        : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =     .326193 (p90)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
3._at        : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =           0
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
4._at        : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =           1
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
5._at        : p               =    .0020737 (mean)
               dem1            =           1
               dem2            =           1
               jointdem        =           1
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
6._at        : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .3356705 (p10)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
7._at        : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .5306735 (p90)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
8._at        : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =           5 (p10)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
9._at        : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =           7 (p90)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
10._at       : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =           0
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
11._at       : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =           1
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
12._at       : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =     .042565 (p10)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
13._at       : p               =    .0020737 (mean)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .9710805 (p90)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
14._at       : p               =    .0003972 (p10)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)
15._at       : p               =    .0039736 (p90)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
         _at |
          1  |   .0006822   .0000535    12.75   0.000     .0005773     .000787
          2  |    .000859    .000077    11.16   0.000     .0007081    .0010099
          3  |   .0006928   .0000479    14.45   0.000     .0005989    .0007867
          4  |   .0167667   .0017289     9.70   0.000     .0133782    .0201553
          5  |   .0005709   .0000907     6.29   0.000     .0003932    .0007487
          6  |   .0009678    .000088    11.00   0.000     .0007954    .0011403
          7  |   .0006751   .0000553    12.21   0.000     .0005667    .0007834
          8  |   .0006541   .0000497    13.16   0.000     .0005567    .0007514
          9  |   .0009698   .0000887    10.94   0.000      .000796    .0011436
         10  |    .000713    .000051    13.97   0.000      .000613     .000813
         11  |   .0022276   .0006703     3.32   0.001     .0009138    .0035414
         12  |   .0006651   .0000683     9.74   0.000     .0005312    .0007989
         13  |   .0008561   .0000789    10.86   0.000     .0007015    .0010106
         14  |   .0005704   .0000405    14.07   0.000      .000491    .0006499
         15  |   .0010493   .0000749    14.00   0.000     .0009024    .0011962
------------------------------------------------------------------------------

. 
. */ Use these to generate Table 3.1 */
. 
. */ Figure 3.14 */
. 
. margins, atmeans at((min)p) at((p10)p) at((p20)p) at((p30)p) at((p40)p) at((p50)p) at((p60)p) at((p70)p) at((p80)p) at
> ((p90)p)

Adjusted predictions                              Number of obs   =     426636
Model VCE    : Robust

Expression   : Pr(cwinit), predict()

1._at        : p               =    2.69e-20 (min)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

2._at        : p               =    .0003972 (p10)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

3._at        : p               =    .0010459 (p20)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

4._at        : p               =    .0013203 (p30)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

5._at        : p               =    .0015324 (p40)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

6._at        : p               =    .0017297 (p50)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

7._at        : p               =    .0019568 (p60)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

8._at        : p               =    .0022387 (p70)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

9._at        : p               =    .0027973 (p80)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

10._at       : p               =    .0039736 (p90)
               dem1            =    .3327872 (mean)
               dem2            =    .2962854 (mean)
               jointdem        =    .1035145 (mean)
               sideabof        =    .5289634 (mean)
               defpact         =    .0549508 (mean)
               contigld        =     .028563 (mean)
               syscon          =    .2727284 (mean)
               satisdy         =    .4671718 (mean)
               numGPs          =     5.75624 (mean)
               cwpceyrs1       =   -17579.62 (mean)
               cwpceyrs2       =   -34237.94 (mean)
               cwpceyrs3       =   -48942.74 (mean)

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
         _at |
          1  |   .0005331   .0000388    13.72   0.000      .000457    .0006092
          2  |   .0005704   .0000405    14.07   0.000      .000491    .0006499
          3  |   .0006371   .0000439    14.52   0.000     .0005511    .0007231
          4  |   .0006676   .0000455    14.66   0.000     .0005784    .0007569
          5  |   .0006922    .000047    14.74   0.000     .0006002    .0007843
          6  |   .0007159   .0000484    14.80   0.000     .0006211    .0008107
          7  |   .0007441   .0000502    14.83   0.000     .0006458    .0008425
          8  |   .0007808   .0000526    14.84   0.000     .0006776    .0008839
          9  |   .0008587   .0000583    14.73   0.000     .0007444     .000973
         10  |   .0010493   .0000749    14.00   0.000     .0009024    .0011962
------------------------------------------------------------------------------

. 
. */ CLOSE LOG FILE */
. 
. log close
      name:  <unnamed>
       log:  /home/horom/WhyLeadersFightDyadicReplication.log
  log type:  text
 closed on:  25 Nov 2015, 12:00:03
------------------------------------------------------------------------------------------------------------------------
